From 64d197eeedf68c593a33dfd35986f03126153940 Mon Sep 17 00:00:00 2001 From: syuilo Date: Tue, 28 Aug 2018 15:50:52 +0900 Subject: [PATCH] Improve readability --- src/modules/core/index.ts | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/modules/core/index.ts b/src/modules/core/index.ts index 4bd67b6..60def40 100644 --- a/src/modules/core/index.ts +++ b/src/modules/core/index.ts @@ -132,7 +132,9 @@ export default class CoreModule implements IModule { incLove(); return true; - } else if (msg.text.includes('おやすみ')) { + } + + if (msg.text.includes('おやすみ')) { if (msg.friend.name) { msg.reply(serifs.core.goodNightWithName.replace('{name}', msg.friend.name)); } else { @@ -142,9 +144,9 @@ export default class CoreModule implements IModule { incLove(); return true; - } else { - return false; } + + return false; } private nadenade = (msg: MessageLike): boolean => {