Skip to content

Commit

Permalink
Cross-origin WindowProxy's [[GetOwnProperty]] cannot return undefined
Browse files Browse the repository at this point in the history
Callers do not anticipate it returning undefined in this case and browsers already throw.

Tests: will be added as part of https://bugzilla.mozilla.org/show_bug.cgi?id=1363208.

Fixes whatwg#4252.
  • Loading branch information
annevk authored and mustaqahmed committed Feb 15, 2019
1 parent ee34f5b commit 486709e
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions source
Original file line number Diff line number Diff line change
Expand Up @@ -79242,7 +79242,16 @@ interface <dfn>BarProp</dfn> {
<!-- sort order: https://software.hixie.ch/utilities/js/live-dom-viewer/?saved=2860 -->
</ol>

<li><p>If <var>value</var> is undefined, then return undefined.</p></li>
<li>
<p>If <var>value</var> is undefined, then:</p>

<ol>
<li><p>If ! <span>IsPlatformObjectSameOrigin</span>(<var>W</var>) is true, then return
undefined.</p></li>

<li><p>Throw a <span>"<code>SecurityError</code>"</span> <code>DOMException</code>.</p></li>
</ol>
</li>

<li><p>Return <span>PropertyDescriptor</span>{
[[Value]]: <var>value</var>,
Expand Down Expand Up @@ -81782,7 +81791,7 @@ interface <dfn>Location</dfn> { // but see also <a href="#the-location-interface
<li><p>Let <var>property</var> be ! <span>CrossOriginGetOwnPropertyHelper</span>(<b>this</b>,
<var>P</var>).</p></li>

<li><p>If <var>property</var> is not undefined, return <var>property</var>.</p></li>
<li><p>If <var>property</var> is not undefined, then return <var>property</var>.</p></li>

<li><p>Throw a <span>"<code>SecurityError</code>"</span> <code>DOMException</code>.</p></li>
</ol>
Expand Down

0 comments on commit 486709e

Please sign in to comment.