summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xjs/stmd.js7
1 files changed, 7 insertions, 0 deletions
diff --git a/js/stmd.js b/js/stmd.js
index 29e4c01..13bdbd6 100755
--- a/js/stmd.js
+++ b/js/stmd.js
@@ -346,6 +346,13 @@ var parseEmphasis = function(inlines) {
// giving us <strong><em>
res.numdelims = 1;
}
+
+ if (first_close_delims === 1) {
+ res.numdelims = 2;
+ } else if (first_close_delims === 2) {
+ res.numdelims = 1;
+ }
+
this.pos += res.numdelims;
if (first_close > 0) { // if we've already passed the first closer: