terser 3.13.0 → 3.13.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of terser might be problematic. Click here for more details.
- package/dist/bundle.js +1 -1
- package/dist/bundle.js.map +1 -1
- package/lib/compress.js +12 -5
- package/lib/utils.js +1 -0
- package/package.json +1 -1
package/lib/compress.js
CHANGED
@@ -2064,11 +2064,18 @@ merge(Compressor.prototype, {
|
|
2064
2064
|
};
|
2065
2065
|
if (!all(def.value.properties, diff)) break;
|
2066
2066
|
var p = def.value.properties.filter(function (p) { return p.key === prop; })[0];
|
2067
|
-
p
|
2068
|
-
|
2069
|
-
|
2070
|
-
|
2071
|
-
|
2067
|
+
if (!p) {
|
2068
|
+
def.value.properties.push(make_node(AST_ObjectKeyVal, node, {
|
2069
|
+
key: prop,
|
2070
|
+
value: node.right
|
2071
|
+
}));
|
2072
|
+
} else {
|
2073
|
+
p.value = new AST_Sequence({
|
2074
|
+
start: p.start,
|
2075
|
+
expressions: [p.value.clone(), node.right.clone()],
|
2076
|
+
end: p.end
|
2077
|
+
});
|
2078
|
+
}
|
2072
2079
|
exprs.shift();
|
2073
2080
|
trimmed = true;
|
2074
2081
|
} while (exprs.length);
|
package/lib/utils.js
CHANGED
package/package.json
CHANGED