Skip to content

Commit

Permalink
tweak formatting of parenthesized ternary expression
Browse files Browse the repository at this point in the history
  • Loading branch information
davidchambers committed Jun 10, 2020
1 parent 152b85a commit 8450a4c
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions lib/doctest.js
Original file line number Diff line number Diff line change
Expand Up @@ -481,9 +481,9 @@ function rewrite$js(options, input) {
.concat ([object ([[INPUT, bookend], [OUTPUT, []]])])
.reduce (function(accum, test) {
accum.chunks.push (substring (input, accum.loc, test[INPUT].loc.start));
accum.loc = (test[OUTPUT].length === 0 ?
test[INPUT] :
last (test[OUTPUT])).loc.end;
accum.loc = (
test[OUTPUT].length === 0 ? test[INPUT] : last (test[OUTPUT])
).loc.end;
return accum;
}, {chunks: [], loc: {line: 1, column: 0}})
.chunks;
Expand Down

0 comments on commit 8450a4c

Please sign in to comment.