We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 6683c7d commit 833bd9fCopy full SHA for 833bd9f
1 file changed
src/ps/commands/modnote.tsx
@@ -48,7 +48,7 @@ export const command: PSCommand = {
48
help: 'Sends a modnote to the given room.',
49
syntax: 'CMD [room], [message]',
50
async run({ arg, message, $T, run }) {
51
- const [target, content] = arg.lazySplit(/[,|]/, 1);
+ const [target, content = 'Hi!'] = arg.lazySplit(/[,|]/, 1);
52
const targetRoom = message.parent.getRoom(target);
53
if (!targetRoom) throw new ChatError($T('INVALID_ROOM_ID'));
54
const userInRoom = targetRoom.users.find(user => toId(user) === message.author.id);
@@ -114,6 +114,6 @@ export const command: PSCommand = {
114
);
115
return;
116
}
117
- return run(`modnote send ${arg ?? 'Hi!'}`);
+ return run(`modnote send ${arg}`);
118
},
119
};
0 commit comments