Comparing version 0.1.4 to 0.1.5
@@ -60,3 +60,3 @@ /*! ***************************************************************************** | ||
function runScript(code, allow = []) { | ||
allow.reduce((obj, cur) => { | ||
const allowObj = allow.reduce((obj, cur) => { | ||
obj[cur] = window[cur]; | ||
@@ -137,3 +137,3 @@ return obj; | ||
scrollX, | ||
scrollY }, allow); | ||
scrollY }, allowObj); | ||
if (!Object.isFrozen(String.prototype)) { | ||
@@ -140,0 +140,0 @@ for (const k in allowList) { |
@@ -60,3 +60,3 @@ /*! ***************************************************************************** | ||
function runScript(code, allow = []) { | ||
allow.reduce((obj, cur) => { | ||
const allowObj = allow.reduce((obj, cur) => { | ||
obj[cur] = window[cur]; | ||
@@ -137,3 +137,3 @@ return obj; | ||
scrollX, | ||
scrollY }, allow); | ||
scrollY }, allowObj); | ||
if (!Object.isFrozen(String.prototype)) { | ||
@@ -140,0 +140,0 @@ for (const k in allowList) { |
@@ -66,3 +66,3 @@ (function (global, factory) { | ||
function runScript(code, allow = []) { | ||
allow.reduce((obj, cur) => { | ||
const allowObj = allow.reduce((obj, cur) => { | ||
obj[cur] = window[cur]; | ||
@@ -143,3 +143,3 @@ return obj; | ||
scrollX, | ||
scrollY }, allow); | ||
scrollY }, allowObj); | ||
if (!Object.isFrozen(String.prototype)) { | ||
@@ -146,0 +146,0 @@ for (const k in allowList) { |
{ | ||
"name": "berial", | ||
"version": "0.1.4", | ||
"version": "0.1.5", | ||
"description": "micro frontend", | ||
@@ -5,0 +5,0 @@ "main": "dist/berial.js", |
@@ -99,3 +99,3 @@ export function runScript(code: string, allow: any = []): any { | ||
// custom allow list | ||
...allow | ||
...allowObj | ||
} | ||
@@ -102,0 +102,0 @@ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
151637