diff options
author | Moonchild <mcwerewolf@gmail.com> | 2018-05-02 16:23:14 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-05-02 16:23:14 +0200 |
commit | 04c8f8f8bc2d2dccb6675bd1ed9912f098e76739 (patch) | |
tree | 7d78110b55ac5d72eb9f15584ec18afbb5948670 /services/fxaccounts/FxAccountsProfileClient.jsm | |
parent | 832046aeb726dee290d2827a20d571034b6bc64a (diff) | |
parent | 3442ae7718679a4da8664bdbb561f746e0357203 (diff) | |
download | UXP-04c8f8f8bc2d2dccb6675bd1ed9912f098e76739.tar UXP-04c8f8f8bc2d2dccb6675bd1ed9912f098e76739.tar.gz UXP-04c8f8f8bc2d2dccb6675bd1ed9912f098e76739.tar.lz UXP-04c8f8f8bc2d2dccb6675bd1ed9912f098e76739.tar.xz UXP-04c8f8f8bc2d2dccb6675bd1ed9912f098e76739.zip |
Merge pull request #320 from janekptacijarabaci/instanceof_negations_1
palemoon#1173: Fix unsafe "instanceof" negations
Diffstat (limited to 'services/fxaccounts/FxAccountsProfileClient.jsm')
-rw-r--r-- | services/fxaccounts/FxAccountsProfileClient.jsm | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/services/fxaccounts/FxAccountsProfileClient.jsm b/services/fxaccounts/FxAccountsProfileClient.jsm index 37115a3fa..1e5edc634 100644 --- a/services/fxaccounts/FxAccountsProfileClient.jsm +++ b/services/fxaccounts/FxAccountsProfileClient.jsm @@ -89,7 +89,7 @@ this.FxAccountsProfileClient.prototype = { try { return (yield this._rawRequest(path, method, token)); } catch (ex) { - if (!ex instanceof FxAccountsProfileClientError || ex.code != 401) { + if (!(ex instanceof FxAccountsProfileClientError) || ex.code != 401) { throw ex; } // If this object was instantiated with a token then we don't refresh it. @@ -105,7 +105,7 @@ this.FxAccountsProfileClient.prototype = { try { return (yield this._rawRequest(path, method, token)); } catch (ex) { - if (!ex instanceof FxAccountsProfileClientError || ex.code != 401) { + if (!(ex instanceof FxAccountsProfileClientError) || ex.code != 401) { throw ex; } log.info("Retry fetching the profile still returned a 401 - revoking our token and failing"); |