From 9a88a6ef8951086c17146c57e098704dc26bcd23 Mon Sep 17 00:00:00 2001 From: Dragory <2606411+Dragory@users.noreply.github.com> Date: Wed, 21 Oct 2020 22:26:43 +0300 Subject: [PATCH] Fix multiple inline snippets breaking --- src/data/Thread.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/data/Thread.js b/src/data/Thread.js index 2db3d0c..5b34a8b 100644 --- a/src/data/Thread.js +++ b/src/data/Thread.js @@ -207,7 +207,7 @@ class Thread { }, {}); text = text.replace( - new RegExp(`${config.inlineSnippetStart}(.+)${config.inlineSnippetEnd}`, "i"), + new RegExp(`${config.inlineSnippetStart}(.+?)${config.inlineSnippetEnd}`, "i"), (orig, trigger) => { const snippet = snippetMap[trigger.toLowerCase()]; return snippet != null ? snippet.body : orig;