]> source.dussan.org Git - rspamd.git/commitdiff
[WebUI] Ask for history reset confirmation 1033/head
authorAlexander Moisseev <moiseev@mezonplus.ru>
Sat, 15 Oct 2016 15:18:28 +0000 (18:18 +0300)
committerGitHub <noreply@github.com>
Sat, 15 Oct 2016 15:18:28 +0000 (18:18 +0300)
Issue: #1027
Reported by: @fenice2

interface/js/rspamd.js

index da2c0691791fe4b8036f221e5d89620deff4dc70..7bb7cdf98be4e4675904a03aca3e278da9275b26 100644 (file)
                 }
             });
         }
-        // @update history log
+        // @reset history log
         $('#resetHistory').on('click', function () {
+            if (!confirm("Are you sure you want to reset history log?")) {
+                return
+            };
             if (history) {
                 history.destroy();
                 $('#historyLog').children('tbody').remove();
             });
         });
 
-        // @reset history log
+        // @update history log
         $('#updateHistory').on('click', function () {
             getHistory();
         });