This commit is contained in:
syuilo 2025-11-29 20:53:58 +09:00
parent e19d9cb2c1
commit b7c5ae7214
1 changed files with 2 additions and 1 deletions

View File

@ -205,7 +205,8 @@ export class MfmService {
// block code (<pre><code>)
case 'PRE': {
if (node.childNodes.length === 1 && (node.childNodes[0] instanceof htmlParser.HTMLElement) && node.childNodes[0].tagName === 'CODE') {
console.log(node.childNodes);
if ((node.childNodes[0] instanceof htmlParser.HTMLElement) && node.childNodes[0].tagName === 'CODE') {
text += '\n```\n';
text += getText(node.childNodes[0]);
text += '\n```\n';