diff options
Diffstat (limited to 'notifier.js')
-rw-r--r-- | notifier.js | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/notifier.js b/notifier.js index 07784eb..cb78c9d 100644 --- a/notifier.js +++ b/notifier.js @@ -255,14 +255,14 @@ function bootstrap() { this.options.headers, $U.extend({ asynchronous: true }, this.options.extra) ); - req.addEventListener("onSuccess", $U.bind(this, function(res) { + req.addEventListener("success", $U.bind(this, function(res) { logger.log("initialized"); if (typeof this.parse == "function") this.cache = this.parse(res); if (this.cache) this.initialized = true; })); - req.addEventListener("onFailure", function(res) { logger.log(res); }); - req.addEventListener("onException", function(res) { logger.log(res); }); + req.addEventListener("failure", function(res) { logger.log(res); }); + req.addEventListener("exception", function(res) { logger.log(res); }); if (this.method == "POST") req.post(); else @@ -277,7 +277,7 @@ function bootstrap() { this.options.headers, $U.extend({ asynchronous: true }, this.options.extra) ); - req.addEventListener("onSuccess", $U.bind(this, function(res) { + req.addEventListener("success", $U.bind(this, function(res) { var parsed, diff; if (typeof this.parse == "function") parsed = this.parse(res); if (parsed && typeof this.diff == "function") diff = this.diff(this.cache, parsed); |