diff options
author | Alex Lam S.L <alexlamsl@gmail.com> | 2018-07-13 01:51:10 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-07-13 01:51:10 +0800 |
commit | bcebacbb9e7ddac7d9c0e4ca2c7e0faf0e0bca7c (patch) | |
tree | fcc19ae9f916dc819753245261f685ac8bb9d34b /lib/utils.js | |
parent | 018a5a750a16dce58ab50d943c47ea6cf01a0fbb (diff) | |
download | tracifyjs-bcebacbb9e7ddac7d9c0e4ca2c7e0faf0e0bca7c.tar.gz tracifyjs-bcebacbb9e7ddac7d9c0e4ca2c7e0faf0e0bca7c.zip |
fix corner cases in `preserve_line` (#3212)
Diffstat (limited to 'lib/utils.js')
-rw-r--r-- | lib/utils.js | 3 |
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) { |