public
/
UglifyJS.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
375c882
)
Fix prop mangling
author
Mihai Bazon
<mihai.bazon@gmail.com>
Mon, 16 Mar 2015 08:53:31 +0000
(10:53 +0200)
committer
Mihai Bazon
<mihai.bazon@gmail.com>
Mon, 16 Mar 2015 08:53:31 +0000
(10:53 +0200)
Even if not “defined”, do mangle if name exists in the cache.
lib/propmangle.js
patch
|
blob
|
history
diff --git
a/lib/propmangle.js
b/lib/propmangle.js
index
41eeffe
..
f79b474
100644
(file)
--- a/
lib/propmangle.js
+++ b/
lib/propmangle.js
@@
-145,7
+145,8
@@
function mangle_properties(ast, options) {
}
function should_mangle(name) {
- return names_to_mangle.indexOf(name) >= 0;
+ return cache.props.has(name)
+ || names_to_mangle.indexOf(name) >= 0;
}
function add(name) {