mirror of
https://github.com/syuilo/ai.git
synced 2024-11-12 17:08:00 +00:00
Validate name
This commit is contained in:
parent
8d0992d8d5
commit
eb6c1021e9
|
@ -80,6 +80,11 @@ export default class CoreModule implements IModule {
|
|||
return true;
|
||||
}
|
||||
|
||||
if (name.includes('@')) {
|
||||
msg.reply(serifs.core.invalidName);
|
||||
return true;
|
||||
}
|
||||
|
||||
const titles = ['さん', 'くん', '君', 'ちゃん', '様', '先生'];
|
||||
|
||||
const withSan = titles.some(t => name.endsWith(t));
|
||||
|
|
|
@ -8,6 +8,7 @@ export default {
|
|||
goodNight: 'おやすみなさい!',
|
||||
goodNightWithName: 'おやすみなさい、{name}!',
|
||||
tooLong: '長すぎる気がします...',
|
||||
invalidName: '発音が難しい気がします',
|
||||
requireMoreLove: 'もっと仲良くなったら考えてあげてもいいですよ?',
|
||||
happyBirthday: 'お誕生日おめでとうございます🎉',
|
||||
happyBirthdayWithName: 'お誕生日おめでとうございます、{name}🎉',
|
||||
|
|
Loading…
Reference in a new issue