diff options
author | John MacFarlane <jgm@berkeley.edu> | 2014-09-11 09:10:03 -0700 |
---|---|---|
committer | John MacFarlane <jgm@berkeley.edu> | 2014-09-11 11:17:41 -0700 |
commit | 2fc6c0d06f4199f4e7ee6fb0e46337bfc6749d24 (patch) | |
tree | 306343dd1d0f16913bffc32206cecb0a5bad6d77 /js | |
parent | c11c900b618f6ca48f37ff1bdd2b9602317ec177 (diff) |
Add check for null in last_emphasis_closer.
Diffstat (limited to 'js')
-rwxr-xr-x | js/stmd.js | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -299,7 +299,8 @@ var parseEmphasis = function() { res = this.scanDelims(c); numclosedelims = res.numdelims; if (res.can_close) { - if (last_emphasis_closer < this.pos) { + if (last_emphasis_closer === null || + last_emphasis_closer < this.pos) { last_emphasis_closer = this.pos; } if (numclosedelims === 3 && delims_to_match === 3) { |