You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When returning a result object from shovel.js, you're using util.inspect - however, an object passed this way will not be usable on the other side (after JSON.parse, it will be a string that can't be turned back to a JSON, unless one uses eval()). Omitting util.inspect would be enough for this to work as JSON.stringify works recursively.
The text was updated successfully, but these errors were encountered:
It does seem that JSON.stringify() would be nicer. Is there a reason to stick with util.inspect() here? (Asked with humility, as I'm pretty new to node.js.)
I believe the way I am using Sandbox is such that, running eval() on output.result should be safe.. but this gives me a bit of heebie jeebies.. It would be nice if I could just use JSON.parse directly.
When returning a result object from shovel.js, you're using util.inspect - however, an object passed this way will not be usable on the other side (after JSON.parse, it will be a string that can't be turned back to a JSON, unless one uses eval()). Omitting util.inspect would be enough for this to work as JSON.stringify works recursively.
The text was updated successfully, but these errors were encountered: