fix setrealmfn

This commit is contained in:
velzie 2024-10-13 13:32:48 -04:00
parent dfb3f485c3
commit 0ab562a28e
No known key found for this signature in database
GPG key ID: AA51AEFB0A1F3820

View file

@ -7,7 +7,7 @@ export default function (client: ScramjetClient, self: typeof globalThis) {
// object.$setrealm({}).postMessage(...)
// the empty object is the "pollutant" which can reconstruct the real realm
// i explain more in postmessage.ts
Object.defineProperty(self.Object.prototype, config.setrealmfn, {
Object.defineProperty(self.Object.prototype, config.globals.setrealmfn, {
value(pollution: {}) {
// this is bad!! sites could detect this
Object.defineProperty(this, POLLUTANT, {