Procházet zdrojové kódy

Merge pull request #5564 from code-october/fix/html-code

fix quoteEnd extract regex
Lloyd Zhou před 1 rokem
rodič
revize
0c697e123d
1 změnil soubory, kde provedl 1 přidání a 1 odebrání
  1. 1 1
      app/components/markdown.tsx

+ 1 - 1
app/components/markdown.tsx

@@ -252,7 +252,7 @@ function tryWrapHtmlCode(text: string) {
       },
     )
     .replace(
-      /(<\/body>)([\r\n\s]*?)(<\/html>)([\n\r]*?)([`]*?)([\n\r]*?)/g,
+      /(<\/body>)([\r\n\s]*?)(<\/html>)([\n\r]*)([`]*)([\n\r]*?)/g,
       (match, bodyEnd, space, htmlEnd, newLine, quoteEnd) => {
         return !quoteEnd ? bodyEnd + space + htmlEnd + "\n```\n" : match;
       },