improve unsafe evaluate of function (#2936)

Miscellaneous
- simplify `run_code()` hack
This commit is contained in:
Alex Lam S.L
2018-02-19 18:47:02 +08:00
committed by GitHub
parent b5f0f4f3a1
commit 70474310f3
2 changed files with 2 additions and 14 deletions

View File

@@ -2344,7 +2344,7 @@ merge(Compressor.prototype, {
var fn = function() {};
fn.node = this;
fn.toString = function() {
return this.node.print_to_string();
return "function(){}";
};
return fn;
}