From 20b18846972aa0da189db2b57ff0ab4e7c05ab2b Mon Sep 17 00:00:00 2001 From: Daniel Thee Roperto Date: Fri, 23 Sep 2016 16:15:05 +1000 Subject: [PATCH] Issue #32 - Fixed JavaScript code to comply with Moodle 27 and Moodle 28 rules. --- views/warningbar/warningbar.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/views/warningbar/warningbar.js b/views/warningbar/warningbar.js index b4588f2..c359e4c 100644 --- a/views/warningbar/warningbar.js +++ b/views/warningbar/warningbar.js @@ -61,7 +61,7 @@ var auth_outage_warningbar = { if (this.preview) { // If one second before finish time, enfore finish. Otherwise, never finish it. - if (this.servertime == this.stops - 1) { + if (this.servertime === this.stops - 1) { this.finish(); } else { @@ -84,8 +84,8 @@ var auth_outage_warningbar = { }, ajaxCheckFinished: function (ajax) { - if (ajax.readyState == XMLHttpRequest.DONE) { - if (ajax.status == 200) { + if (ajax.readyState === XMLHttpRequest.DONE) { + if (ajax.status === 200) { if (ajax.responseText.trim() === 'finished') { this.finish(); }