summaryrefslogtreecommitdiffstats
path: root/core/js
diff options
context:
space:
mode:
authorMorris Jobke <hey@morrisjobke.de>2015-04-08 18:02:00 +0200
committerMorris Jobke <hey@morrisjobke.de>2015-04-08 18:02:00 +0200
commit78ec7543d50ff3ab269e4d668730405841038c6b (patch)
treea4bb7a5418c068ba9a59a31b72e01b97ad20d373 /core/js
parentfc2711e15695f0be8e353a0237e5f1f5b5dc4389 (diff)
downloadnextcloud-server-78ec7543d50ff3ab269e4d668730405841038c6b.tar.gz
nextcloud-server-78ec7543d50ff3ab269e4d668730405841038c6b.zip
Fix maintenance refresh interval
* fix XMLHttpRequest - send after callback is registered * check for correct type of value - it's a boolean * return correct content-type in status.php
Diffstat (limited to 'core/js')
-rw-r--r--core/js/maintenance-check.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/core/js/maintenance-check.js b/core/js/maintenance-check.js
index 8ca00456fef..061a434214b 100644
--- a/core/js/maintenance-check.js
+++ b/core/js/maintenance-check.js
@@ -7,14 +7,14 @@ function checkStatus() {
0, location.pathname.indexOf('index.php')
);
request.open("GET", ocroot+'status.php', true);
- request.send();
request.onreadystatechange = function() {
if (request.readyState === 4) {
var response = request.responseText;
var responseobj = JSON.parse(response);
- if (responseobj.maintenance === 'false') {
+ if (responseobj.maintenance === false) {
window.location.reload();
}
}
};
+ request.send();
}