Skip to content

Commit

Permalink
Proxy resolves other proxies
Browse files Browse the repository at this point in the history
  • Loading branch information
NDevTK authored Nov 14, 2024
1 parent a9c9633 commit dced131
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion WindowScript.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@
if (proxies.has(object)) {
return proxies.get(object);
}
if (!handler) return;
const p = new Proxy(object, handler);
proxies.set(object, p);
return p;
Expand Down Expand Up @@ -130,7 +131,7 @@
get: function(target, property) {
// property might not exist.
try {
if (property !== "postMessage") return Reflect.get(...arguments);
if (property !== "postMessage") return useProxy(Reflect.get(...arguments));
} catch {}
return function() {
hook(arguments, type, iframe);
Expand Down

0 comments on commit dced131

Please sign in to comment.