Skip to content

Commit

Permalink
Fix globals evaluation (#377)
Browse files Browse the repository at this point in the history
(symbol, "javascript code") should be mapped to (symbol, value).
  • Loading branch information
remo5000 authored Sep 21, 2018
1 parent 6daf643 commit 152b8e2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/utils/castBackend.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ export const castLibrary = (lib: any): Library => ({
globals: Object.entries(lib.globals as object).map(entry => {
/** The value that is passed is evaluated into an actual JS value */
try {
entry[0] = (window as any).eval(entry[1])
entry[1] = (window as any).eval(entry[1])
} catch (e) {}
return entry
})
Expand Down

0 comments on commit 152b8e2

Please sign in to comment.