summaryrefslogtreecommitdiff
path: root/misc/update.js
diff options
context:
space:
mode:
Diffstat (limited to 'misc/update.js')
-rw-r--r--misc/update.js6
1 files changed, 5 insertions, 1 deletions
diff --git a/misc/update.js b/misc/update.js
index 2586fbf50..e595e4cb2 100644
--- a/misc/update.js
+++ b/misc/update.js
@@ -12,7 +12,11 @@ if (isJsEnabled()) {
}
}
- var progress = new progressBar('updateprogress', updateCallback, HTTPPost);
+ errorCallback = function (pb) {
+ window.location = window.location.href.split('op=')[0] +'op=error';
+ }
+
+ var progress = new progressBar('updateprogress', updateCallback, HTTPPost, errorCallback);
progress.setProgress(-1, 'Starting updates');
$('progress').appendChild(progress.element);
progress.startMonitoring('update.php?op=do_update', 0);