mirror of
https://github.com/zotero/zotero.git
synced 2026-10-04 02:31:47 +00:00
renderItemTitle(): Fix nested tag handling when rendering to string
Need to exit the loop regardless of whether we're rendering actual nodes. Fixes #5082
This commit is contained in:
parent
66d83ec4c8
commit
5ae1986f79
1 changed files with 3 additions and 1 deletions
|
|
@ -2465,12 +2465,14 @@ Zotero.Utilities.Internal = {
|
|||
let discardedNode = nodeStack.pop();
|
||||
if (discardedMarkup.beginsTag === markup.endsTag) {
|
||||
nodeStack[nodeStack.length - 1].append(discardedNode);
|
||||
break;
|
||||
}
|
||||
else {
|
||||
nodeStack[nodeStack.length - 1].append(discardedMarkup.token, ...discardedNode.childNodes);
|
||||
}
|
||||
}
|
||||
if (discardedMarkup.beginsTag === markup.endsTag) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
continue;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue