I am currently using Edge 44.18362, I have an authentication window, and a parent window which opens it, once the authentication is done I am posting the message to the parent(opener window) like this
$window.opener.postMessage(data,URL);
and I am listening to the event in the parent window like this.
window.addEventListener('message', someFunc, false);
and someFunc() is defined like this
function someFunc(windowData){
//here I am accessing source as windowData.source
}
I am trying to access the source attribute of MessageEvent to access the URL and stuff. in Chrome/Firefox I am able to access source object and functionality works fine, but when it comes to Edge I am not able to access source object and I see this error in console.

Added try-catch around the block of code, this is the error I see.

What is going wrong here, what can be done to fix this?