Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FIX regression devtool, in case of cross domain parent, window.parent might throw #4199

Merged
merged 1 commit into from
Sep 20, 2018

Conversation

ndelangen
Copy link
Member

I caused a regression, this fixes it.

The regression occurs when the iframe and parent are on different domains or the manager frame itself is iframed in on a different domain.

calling window.parent might throw, so a try-catch is added.

@tmeasday

@ndelangen ndelangen added the bug label Sep 18, 2018
@ndelangen ndelangen self-assigned this Sep 18, 2018
@ndelangen ndelangen requested a review from tmeasday September 18, 2018 21:41
@tmeasday
Copy link
Member

Seems reasonable to me! Not sure we need the console.log, but no harm I guess

@codecov
Copy link

codecov bot commented Sep 20, 2018

Codecov Report

Merging #4199 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@          Coverage Diff           @@
##           master   #4199   +/-   ##
======================================
  Coverage    40.6%   40.6%           
======================================
  Files         491     491           
  Lines        5832    5832           
  Branches      780     780           
======================================
  Hits         2368    2368           
  Misses       3088    3088           
  Partials      376     376

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 0ad9b39...86e8dd4. Read the comment docs.

@pksunkara pksunkara merged commit 15711f1 into master Sep 20, 2018
@pksunkara pksunkara deleted the fix/regression-cross-domain-devtool branch September 20, 2018 09:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants