summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@highsecure.ru>2018-07-02 13:25:59 +0100
committerGitHub <noreply@github.com>2018-07-02 13:25:59 +0100
commit3312e1ac6aabbbf602d168e7947145eda3065d2d (patch)
tree7f34b7816d813f30255ca26700cb2be505b3bf29
parent00e49cd7f7351f587000393b05787c616456249f (diff)
parentd649c1329fde549ce52f4195db90083c8c7fe834 (diff)
downloadrspamd-3312e1ac6aabbbf602d168e7947145eda3065d2d.tar.gz
rspamd-3312e1ac6aabbbf602d168e7947145eda3065d2d.zip
Merge pull request #2319 from moisseev/const
[WebUI] Stop using "const" declaration
-rw-r--r--interface/js/app/graph.js2
-rw-r--r--interface/js/app/history.js6
-rw-r--r--interface/js/app/rspamd.js2
3 files changed, 5 insertions, 5 deletions
diff --git a/interface/js/app/graph.js b/interface/js/app/graph.js
index 9ae6a9297..20fa36f53 100644
--- a/interface/js/app/graph.js
+++ b/interface/js/app/graph.js
@@ -175,7 +175,7 @@ function($, D3Evolution, unused) {
// Autoranging
var scaleFactor = 1;
var unit = "msg/s";
- const yMax = d3.max(d3.merge(data), function (d) { return d.y; });
+ var yMax = d3.max(d3.merge(data), function (d) { return d.y; });
if (yMax < 1) {
scaleFactor = 60;
unit = "msg/min";
diff --git a/interface/js/app/history.js b/interface/js/app/history.js
index 3c62983ad..fbae27959 100644
--- a/interface/js/app/history.js
+++ b/interface/js/app/history.js
@@ -115,7 +115,7 @@ function($, _, Humanize) {
function process_history_v2(data) {
// Display no more than rcpt_lim recipients
- const rcpt_lim = 3;
+ var rcpt_lim = 3;
var items = [];
function getSelector(id) {
@@ -133,7 +133,7 @@ function($, _, Humanize) {
$.each(data.rows,
function (i, item) {
function more(p) {
- const l = item[p].length;
+ var l = item[p].length;
return (l > rcpt_lim) ? " … (" + l + ")" : "";
}
function format_rcpt(smtp, mime) {
@@ -556,7 +556,7 @@ function($, _, Humanize) {
if (checked_server === "All SERVERS") {
rspamd.queryNeighbours("history", function (req_data) {
function differentVersions() {
- const dv = neighbours_data.some(function (e) {
+ var dv = neighbours_data.some(function (e) {
return e.version !== neighbours_data[0].version;
});
if (dv) {
diff --git a/interface/js/app/rspamd.js b/interface/js/app/rspamd.js
index 1b90cb27e..120f746c4 100644
--- a/interface/js/app/rspamd.js
+++ b/interface/js/app/rspamd.js
@@ -165,7 +165,7 @@ define(['jquery', 'd3pie', 'visibility', 'app/stats', 'app/graph', 'app/config',
}
function alertMessage(alertClass, alertText) {
- const a = $('<div class="alert ' + alertClass + ' alert-dismissible fade in show">' +
+ var a = $('<div class="alert ' + alertClass + ' alert-dismissible fade in show">' +
'<button type="button" class="close" data-dismiss="alert" title="Dismiss">&times;</button>' +
'<strong>' + alertText + '</strong>');
$('.notification-area').append(a);