Refactoring - resolve code inspection problems.

This commit is contained in:
Alexander Zobnin
2015-07-24 19:33:22 +03:00
parent 0df92cf580
commit 12be5fff56
6 changed files with 107 additions and 76 deletions

View File

@@ -115,7 +115,7 @@ function (angular, _, kbn) {
// Remove hostnames from item names and then
// extract item names
// "hostname: itemname" --> "itemname"
var delete_hostname_pattern = /(?:\[[\w\.]+\]\:\s)/g;
var delete_hostname_pattern = /(?:\[[\w\.]+]:\s)/g;
var itemnames = zabbixHelperSrv.splitMetrics(itemname.replace(delete_hostname_pattern, ''));
// Find items by item names and perform queries
@@ -323,7 +323,7 @@ function (angular, _, kbn) {
annotation: annotation,
time: e.clock * 1000,
title: Number(e.value) ? 'Problem' : 'OK',
text: objects[e.objectid].description + formatted_acknowledges,
text: objects[e.objectid].description + formatted_acknowledges
});
});
return events;