Bug 1160333 - When denying permission, use the string 'PermissionDeniedError'. r=nsm
authorDoug Turner <doug.turner@gmail.com>
Fri, 01 May 2015 11:01:17 -0700
changeset 273466 9681ac761aeab2a584b7c98804bc6be0bcf49827
parent 273465 2e3340d6bbcf10c8ddab17165140fbd2ededf4b6
child 273467 304554a697fe7497de04903df63895a5931eb514
push id863
push userraliiev@mozilla.com
push dateMon, 03 Aug 2015 13:22:43 +0000
treeherdermozilla-release@f6321b14228d [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersnsm
bugs1160333
milestone40.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1160333 - When denying permission, use the string 'PermissionDeniedError'. r=nsm
dom/push/Push.js
--- a/dom/push/Push.js
+++ b/dom/push/Push.js
@@ -257,17 +257,17 @@ Push.prototype = {
           this._cpmm.sendAsyncMessage("Push:Register", {
                                       pageURL: this._pageURL.spec,
                                       scope: this._scope,
                                       requestID: resolverId
                                     });
         }.bind(this),
 
         function() {
-          reject("denied");
+          reject("PermissionDeniedError");
         }
       );
     }.bind(this));
     return p;
   },
 
   getSubscription: function() {
     debug("getSubscription()" + this._scope);
@@ -281,17 +281,17 @@ Push.prototype = {
           this._cpmm.sendAsyncMessage("Push:Registration", {
                                       pageURL: this._pageURL.spec,
                                       scope: this._scope,
                                       requestID: resolverId
                                     });
         }.bind(this),
 
         function() {
-          reject("denied");
+          reject("PermissionDeniedError");
         }
       );
     }.bind(this));
     return p;
   },
 
   hasPermission: function() {
     debug("getSubscription()" + this._scope);