From 4b399a52304e35091451d77f204b56e09743dc12 Mon Sep 17 00:00:00 2001 From: Grzesiek11 Date: Sat, 6 Jan 2024 02:53:52 +0100 Subject: [PATCH] Use simpler replace value --- src/plugins/fixCodeblockGap/index.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/plugins/fixCodeblockGap/index.ts b/src/plugins/fixCodeblockGap/index.ts index c76247f82fc..243be0195e6 100644 --- a/src/plugins/fixCodeblockGap/index.ts +++ b/src/plugins/fixCodeblockGap/index.ts @@ -27,8 +27,8 @@ export default definePlugin({ { find: ".default.Messages.DELETED_ROLE_PLACEHOLDER", replacement: { - match: String.raw`/^${"```"}(?:([a-z0-9_+\-.#]+?)\n)?\n*([^\n][^]*?)\n*${"```"}/`, - replace: String.raw`/^${"```"}(?:([a-z0-9_+\-.#]+?)\n)?\n*([^\n][^]*?)\n*${"```"}\n?/`, + match: String.raw`/^${"```"}(?:([a-z0-9_+\-.#]+?)\n)?\n*([^\n][^]*?)\n*${"```"}`, + replace: "$&\\n?", }, }, ],