From 5d60484553895a0eac1ac764d1fa7fc683c8499d Mon Sep 17 00:00:00 2001 From: Mihai Bazon Date: Sun, 5 Apr 2015 13:19:46 +0300 Subject: [PATCH] More fixes for the breaking changes in yargs Close #670 --- bin/uglifyjs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/bin/uglifyjs b/bin/uglifyjs index 9b335b74..df7b7832 100755 --- a/bin/uglifyjs +++ b/bin/uglifyjs @@ -215,7 +215,7 @@ if (ARGS.keep_fnames) { if (BEAUTIFY) UglifyJS.merge(OUTPUT_OPTIONS, BEAUTIFY); -if (ARGS.comments) { +if (ARGS.comments != null) { if (/^\/.*\/[a-zA-Z]*$/.test(ARGS.comments)) { var regex_pos = ARGS.comments.lastIndexOf("/"); try { @@ -357,11 +357,11 @@ async.eachLimit(files, 1, function (file, cb) { TOPLEVEL = UglifyJS.AST_Node.from_mozilla_ast(TOPLEVEL); }); - if (ARGS.wrap) { + if (ARGS.wrap != null) { TOPLEVEL = TOPLEVEL.wrap_commonjs(ARGS.wrap, ARGS.export_all); } - if (ARGS.enclose) { + if (ARGS.enclose != null) { var arg_parameter_list = ARGS.enclose; if (arg_parameter_list === true) { arg_parameter_list = []; -- 2.34.1