diff options
author | John MacFarlane <jgm@berkeley.edu> | 2014-09-11 09:34:29 -0700 |
---|---|---|
committer | John MacFarlane <jgm@berkeley.edu> | 2014-09-11 11:17:42 -0700 |
commit | 0efcb9ff947ee9fcda77f317f2bec811160dca4a (patch) | |
tree | 01321a0d7a797b5f89031643d8d562ef9ee6bdb9 | |
parent | e6c06dbb715f59b5b9dd4ad7fb7090f83e3ad90d (diff) |
jshint improvements.
-rwxr-xr-x | js/stmd.js | 12 |
1 files changed, 7 insertions, 5 deletions
@@ -265,7 +265,7 @@ var startpos = this.pos; var c ; var first_close = 0; - var c = this.peek(); + c = this.peek(); if (!(c === '*' || c === '_')) { return null; } @@ -324,7 +324,7 @@ this.last_emphasis_closer = null; return inlines[0]; } - } else if (next_inline = this.parseInline()) { + } else if ((next_inline = this.parseInline())) { inlines.push(next_inline); } else { break; @@ -396,7 +396,9 @@ this.parseBackticks(); break; case '<': - this.parseAutolink() || this.parseHtmlTag() || this.parseString(); + if (!(this.parseAutolink())) { + this.parseHtmlTag(); + } break; case '[': // nested [] nest_level++; @@ -515,7 +517,7 @@ // a special meaning in markdown, as a plain string, adding to inlines. var parseString = function() { var m; - if (m = this.match(reMain)) { + if ((m = this.match(reMain))) { return { t: 'Str', c: m }; } else { return null; @@ -676,7 +678,7 @@ this.last_emphasis_closer = null; var inlines = []; var next_inline; - while (next_inline = this.parseInline()) { + while ((next_inline = this.parseInline())) { inlines.push(next_inline); } return inlines; |