Closed daoodk closed 4 years ago
@daoodk Please give us details about your use case and steps to reproduce. It's hard reproduce this issue by just looking at this error.
@nehaagrawal, I am encountering the same error whenever executing handleWindowCallback() from an iFrame.
It appears that the problem is in AuthenticationContext.prototype.handleWindowCallback where the default value for the variable 'self' is set to null. In all other areas in the library, it is defaulted to 'this' instead. Changing to 'this' in my local copy resolved the issue.
@nehaagrawal, I believe the details provided above should provide the information you need to reproduce/investigate/resolve. Please advise if any additional information is required.
Found in AdalJS v1.0.17
Uncaught TypeError: Cannot read property 'getRequestInfo' of null at AuthenticationContext.handleWindowCallback (adal.js:1324)
At line 1315, this._openedWindows.length === 0. At line 1320, windows.parent._adalInstance is undefined.
Neither the if, nor the else if condition is met above, so 'self' remains null.
Line 1324 calls self.getRequestInfo(hash) which fails.
Interestingly, this.getRequestInfo(hash) returns a valid object at this point.