better eval contexts in bin/6to5-node
This commit is contained in:
parent
3b9a339c79
commit
45cb755845
@ -35,11 +35,9 @@ to5.register(registerOpts);
|
||||
|
||||
//
|
||||
|
||||
var context = vm.createContext({});
|
||||
|
||||
var _eval = function (code, filename) {
|
||||
code = to5.transform(code, { filename: filename, blacklist: ["useStrict"] }).code;
|
||||
return vm.runInContext(code, context, filename);
|
||||
return vm.runInThisContext(code, filename);
|
||||
};
|
||||
|
||||
if (commander.eval) {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user