aboutsummaryrefslogtreecommitdiff
path: root/lib/utils.js
diff options
context:
space:
mode:
authorAlex Lam S.L <alexlamsl@gmail.com>2018-07-13 01:51:10 +0800
committerGitHub <noreply@github.com>2018-07-13 01:51:10 +0800
commitbcebacbb9e7ddac7d9c0e4ca2c7e0faf0e0bca7c (patch)
treefcc19ae9f916dc819753245261f685ac8bb9d34b /lib/utils.js
parent018a5a750a16dce58ab50d943c47ea6cf01a0fbb (diff)
downloadtracifyjs-bcebacbb9e7ddac7d9c0e4ca2c7e0faf0e0bca7c.tar.gz
tracifyjs-bcebacbb9e7ddac7d9c0e4ca2c7e0faf0e0bca7c.zip
fix corner cases in `preserve_line` (#3212)
Diffstat (limited to 'lib/utils.js')
-rw-r--r--lib/utils.js3
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/utils.js b/lib/utils.js
index 7a51fb80..4a61623a 100644
--- a/lib/utils.js
+++ b/lib/utils.js
@@ -162,8 +162,7 @@ var MAP = (function() {
})();
function push_uniq(array, el) {
- if (array.indexOf(el) < 0)
- array.push(el);
+ if (array.indexOf(el) < 0) return array.push(el);
}
function string_template(text, props) {