Skip to content

Commit

Permalink
Merge pull request #758 from mathjax/issue2788
Browse files Browse the repository at this point in the history
Handle document created by parsing in XHTML.  (mathjax/MathJax#2788)
  • Loading branch information
dpvc authored Apr 6, 2022
2 parents db04605 + 8f3993c commit 588d515
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions ts/adaptors/HTMLAdaptor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -227,21 +227,21 @@ AbstractDOMAdaptor<N, T, D> implements MinHTMLAdaptor<N, T, D> {
* @override
*/
public head(doc: D) {
return doc.head;
return doc.head || (doc as any as N);
}

/**
* @override
*/
public body(doc: D) {
return doc.body;
return doc.body || (doc as any as N);
}

/**
* @override
*/
public root(doc: D) {
return doc.documentElement;
return doc.documentElement || (doc as any as N);
}

/**
Expand Down

0 comments on commit 588d515

Please sign in to comment.