From 82bc350345e848016cd83c88cc084afb1f93bbbf Mon Sep 17 00:00:00 2001 From: na2na <49822810+na2na-p@users.noreply.github.com> Date: Mon, 11 Apr 2022 09:52:48 +0900 Subject: [PATCH] =?UTF-8?q?=E5=85=AC=E9=96=8B=E7=AF=84=E5=9B=B2=E3=82=92?= =?UTF-8?q?=E7=90=86=E7=94=B1=E3=81=AB=E6=8B=92=E5=90=A6=E3=81=95=E3=82=8C?= =?UTF-8?q?=E3=81=9F=E9=9A=9B=E3=81=AE=E3=82=BB=E3=83=AA=E3=83=95=E3=81=AE?= =?UTF-8?q?=E5=A4=89=E6=9B=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/modules/reminder/index.ts | 7 ++++++- src/serifs.ts | 2 ++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/src/modules/reminder/index.ts b/src/modules/reminder/index.ts index bfebb31..f104037 100644 --- a/src/modules/reminder/index.ts +++ b/src/modules/reminder/index.ts @@ -59,8 +59,13 @@ export default class extends Module { const separatorIndex = text.indexOf(' ') > -1 ? text.indexOf(' ') : text.indexOf('\n'); const thing = text.substr(separatorIndex + 1).trim(); - if (thing === '' && msg.quoteId == null || msg.visibility === 'followers') { + if (thing === '' && msg.quoteId == null) { msg.reply(serifs.reminder.invalid); + return true; + } + + if (msg.visibility === 'followers') { + msg.reply(serifs.reminder.invalidVisibility); return { reaction: '๐Ÿ†–', immediate: true, diff --git a/src/serifs.ts b/src/serifs.ts index 7d61ba3..d349cd9 100644 --- a/src/serifs.ts +++ b/src/serifs.ts @@ -339,6 +339,8 @@ export default { reminder: { invalid: 'ใ†ใƒผใ‚“...๏ผŸ', + invalidVisibility: "ๅ…ฌ้–‹็ฏ„ๅ›ฒใฎๆŒ‡ๅฎšใ‚’ๅค‰ใˆใฆใฟใฆ", + reminds: 'ใ‚„ใ‚‹ใ“ใจไธ€่ฆงใงใ™๏ผ', notify: (name) => name ? `${name}ใ€ใ“ใ‚Œใ‚„ใ‚Šใพใ—ใŸใ‹๏ผŸ` : `ใ“ใ‚Œใ‚„ใ‚Šใพใ—ใŸใ‹๏ผŸ`,