aboutsummaryrefslogtreecommitdiff
path: root/bin/uglifyjs
diff options
context:
space:
mode:
authorMihai Bazon <mihai@bazon.net>2013-07-28 11:11:11 +0300
committerMihai Bazon <mihai@bazon.net>2013-07-28 11:11:11 +0300
commit3435af494f62c59ce0d769e762966b91c57090b4 (patch)
treea74801b1cb1419c665af134fd118a1f0cb4bef35 /bin/uglifyjs
parent41c627379c31b4886091f19fc8385cd8619e645a (diff)
downloadtracifyjs-3435af494f62c59ce0d769e762966b91c57090b4.tar.gz
tracifyjs-3435af494f62c59ce0d769e762966b91c57090b4.zip
Don't require arguments to --enclose
Diffstat (limited to 'bin/uglifyjs')
-rwxr-xr-xbin/uglifyjs7
1 files changed, 4 insertions, 3 deletions
diff --git a/bin/uglifyjs b/bin/uglifyjs
index 2611d960..56ff2235 100755
--- a/bin/uglifyjs
+++ b/bin/uglifyjs
@@ -264,11 +264,12 @@ async.eachLimit(files, 1, function (file, cb) {
if (ARGS.enclose) {
var arg_parameter_list = ARGS.enclose;
-
- if (!(arg_parameter_list instanceof Array)) {
+ if (arg_parameter_list === true) {
+ arg_parameter_list = [];
+ }
+ else if (!(arg_parameter_list instanceof Array)) {
arg_parameter_list = [arg_parameter_list];
}
-
TOPLEVEL = TOPLEVEL.wrap_enclose(arg_parameter_list);
}