aboutsummaryrefslogtreecommitdiff
path: root/lib/minify.js
diff options
context:
space:
mode:
authorAlex Lam S.L <alexlamsl@gmail.com>2018-04-06 13:32:26 +0800
committerGitHub <noreply@github.com>2018-04-06 13:32:26 +0800
commit0b62a28b476c443638d9894e14e4c29b2748143c (patch)
treef91d75d3ad6686c706b9cabc60cd527ea9da3d01 /lib/minify.js
parent44116c6d2bf80f08195f2a7568e80cc57113953f (diff)
downloadtracifyjs-0b62a28b476c443638d9894e14e4c29b2748143c.tar.gz
tracifyjs-0b62a28b476c443638d9894e14e4c29b2748143c.zip
improve usability of `includeSources` (#3057)
Exclude source contents from input source map if `includeSources=false` fixes #3041
Diffstat (limited to 'lib/minify.js')
-rw-r--r--lib/minify.js2
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/minify.js b/lib/minify.js
index 8dc275cf..0e117ed1 100644
--- a/lib/minify.js
+++ b/lib/minify.js
@@ -182,6 +182,8 @@ function minify(files, options) {
} else for (var name in files) if (HOP(files, name)) {
options.output.source_map.get().setSourceContent(name, files[name]);
}
+ } else {
+ options.output.source_map.get()._sourcesContents = null;
}
}
delete options.output.ast;