Permalink
Browse files

fix(authService): storage events do not work properly in IE11

  • Loading branch information...
Adam Willden
Adam Willden committed Sep 19, 2016
1 parent 1aa8b05 commit 944a716c299001d89bc6758fa83408ac7df5dadb
Showing with 8 additions and 0 deletions.
  1. +8 −0 src/authService.js
@@ -84,6 +84,14 @@ export class AuthService {
LogManager.getLogger('authentication').info('Stored token changed event');
// IE runs the event handler before updating the storage value. Update it now.
// An unset storage key in IE is an empty string, where-as chrome is null
if (event.newValue) {
this.authentication.storage.set(this.config.storageKey, event.newValue);
} else {
this.authentication.storage.remove(this.config.storageKey);
}
let wasAuthenticated = this.authenticated;
this.authentication.responseAnalyzed = false;
this.updateAuthenticated();

0 comments on commit 944a716

Please sign in to comment.