mirror of
https://github.com/nullnyat/NullcatChan.git
synced 2025-04-29 08:37:23 +09:00
長い名前は弾くように
This commit is contained in:
parent
805b25bb51
commit
91995c9340
@ -26,6 +26,11 @@ export default class CoreModule implements IModule {
|
|||||||
|
|
||||||
const name = msg.text.match(/^(.+?)って呼んで/)[1];
|
const name = msg.text.match(/^(.+?)って呼んで/)[1];
|
||||||
|
|
||||||
|
if (name.length > 10) {
|
||||||
|
msg.reply(serifs.core.tooLong);
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
const withSan =
|
const withSan =
|
||||||
name.endsWith('さん') ||
|
name.endsWith('さん') ||
|
||||||
name.endsWith('くん') ||
|
name.endsWith('くん') ||
|
||||||
|
@ -7,6 +7,7 @@ export default {
|
|||||||
goodMorningWithName: 'おはようございます、{name}!',
|
goodMorningWithName: 'おはようございます、{name}!',
|
||||||
goodNight: 'おやすみなさい!',
|
goodNight: 'おやすみなさい!',
|
||||||
goodNightWithName: 'おやすみなさい、{name}!',
|
goodNightWithName: 'おやすみなさい、{name}!',
|
||||||
|
tooLong: '長すぎる気がします...'
|
||||||
},
|
},
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
x
Reference in New Issue
Block a user