From ec3ca3032ef20916d1df40be5156bc4a908fa663 Mon Sep 17 00:00:00 2001 From: syuilo Date: Sat, 16 Feb 2019 19:37:05 +0900 Subject: [PATCH] =?UTF-8?q?=E3=83=9F=E3=83=A5=E3=83=BC=E3=83=88=E3=83=AF?= =?UTF-8?q?=E3=83=BC=E3=83=89=E3=81=A7=E6=AD=A3=E8=A6=8F=E8=A1=A8=E7=8F=BE?= =?UTF-8?q?=E3=82=92=E4=BD=BF=E3=81=88=E3=82=8B=E3=82=88=E3=81=86=E3=81=AB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/client/app/common/scripts/should-mute-note.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/client/app/common/scripts/should-mute-note.ts b/src/client/app/common/scripts/should-mute-note.ts index 8a6430b1d..42e167915 100644 --- a/src/client/app/common/scripts/should-mute-note.ts +++ b/src/client/app/common/scripts/should-mute-note.ts @@ -4,7 +4,8 @@ export default function(me, settings, note) { const includesMutedWords = (text: string) => text - ? settings.mutedWords.some(q => q.length > 0 && !q.some(word => !text.includes(word))) + ? settings.mutedWords.some(q => q.length > 0 && !q.some(word => + word.startsWith('/') && word.endsWith('/') ? !(new RegExp(word.substr(1, word.length - 2)).test(text)) : !text.includes(word))) : false; return (