From 3f2ea9bb5c9fefa1fde1d79eb698ccfca999488b Mon Sep 17 00:00:00 2001 From: "anton.borgstrom" Date: Wed, 16 Oct 2024 16:36:56 +0200 Subject: [PATCH] Non greedy regexp if multiple embeds on same line --- scripts/core/editor3/html/from-html/index.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/scripts/core/editor3/html/from-html/index.ts b/scripts/core/editor3/html/from-html/index.ts index 23806faba6..6b5acd6d15 100644 --- a/scripts/core/editor3/html/from-html/index.ts +++ b/scripts/core/editor3/html/from-html/index.ts @@ -66,11 +66,11 @@ class HTMLParser { manageEmbeds(__html: string): string { let html = __html; - const embedCount = html.match(//g)?.length ?? 0; + const embedCount = html.match(//g)?.length ?? 0; for (let i = 0; i < embedCount; i++) { - const startTag = html.match(//); - const endTag = html.match(//); + const startTag = html.match(//); + const endTag = html.match(//); if (startTag == null || endTag == null) { continue;