do not throw error when trying to match tag at the end of the document
This commit is contained in:
parent
5e4facea44
commit
e1a5492a7f
1 changed files with 5 additions and 2 deletions
|
|
@ -545,8 +545,11 @@ var Editor = function(renderer, session) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (token.type.indexOf("tag-open") != -1)
|
if (token.type.indexOf("tag-open") != -1) {
|
||||||
token = iterator.stepForward();
|
token = iterator.stepForward();
|
||||||
|
if (!token)
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
var tag = token.value;
|
var tag = token.value;
|
||||||
var depth = 0;
|
var depth = 0;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue