diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2017-03-30 11:22:22 +0100 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2017-03-30 11:23:13 +0100 |
commit | 6861798ac32905996694d21186d3eb9aeb015682 (patch) | |
tree | 30063f720ed33ebe83bd51d6b809eabf29fa7c73 /interface | |
parent | fafd3e3a7f5d79bd700e7957e5565b056c6c6250 (diff) | |
download | rspamd-6861798ac32905996694d21186d3eb9aeb015682.tar.gz rspamd-6861798ac32905996694d21186d3eb9aeb015682.zip |
[WebUI] Fix legacy history
Issue: #1564
Diffstat (limited to 'interface')
-rw-r--r-- | interface/js/app/history.js | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/interface/js/app/history.js b/interface/js/app/history.js index 24fd7f98a..c04c004ea 100644 --- a/interface/js/app/history.js +++ b/interface/js/app/history.js @@ -427,9 +427,17 @@ function($, _, Humanize) { .map(function (d){ return d.data; }); if (neighbours_data.length > 0) { var data = {}; - data.rows = [].concat.apply([], neighbours_data - .map(function(e) {return e.rows;})); - data.version = neighbours_data[0].version; + if (neighbours_data[0].version) { + data.rows = [].concat.apply([], neighbours_data + .map(function (e) { + return e.rows; + })); + data.version = neighbours_data[0].version; + } + else { + // Legacy version + data = [].concat.apply([], neighbours_data); + } var items = process_history_data(data); ft.history = FooTable.init("#historyTable", { |