Skip to content

Commit

Permalink
Only listen to postMessage from an intended source (broken in dev m…
Browse files Browse the repository at this point in the history
…ode)
  • Loading branch information
camelburrito committed Jan 22, 2016
1 parent 39fa29e commit df49dfa
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/iframe-helper.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ export function listen(iframe, typeOfMessage, callback, opt_is3P) {
if (event.origin != origin && !mode.localDev && !mode.test) {
return;
}
if (event.source != iframe.contentWindow && !mode.localDev && !mode.test) {
if (event.source != iframe.contentWindow) {
return;
}
if (!event.data || event.data.sentinel != sentinel) {
Expand Down

0 comments on commit df49dfa

Please sign in to comment.