Fixed logical typo.
This commit is contained in:
parent
85be251b3f
commit
21feb37d21
|
@ -281,7 +281,7 @@ async function onCommand(args, context, isConversation) {
|
||||||
}
|
}
|
||||||
|
|
||||||
function onMessage(message, context) {
|
function onMessage(message, context) {
|
||||||
const isConversation = message.recipient === config.user.username && !message.type === 'whisper' && !context.containsCommand;
|
const isConversation = message.recipient === config.user.username && message.type !== 'whisper' && !context.containsCommand;
|
||||||
|
|
||||||
if (promptRegex.test(message.body) || isConversation) {
|
if (promptRegex.test(message.body) || isConversation) {
|
||||||
onCommand([message.body.replace(promptRegex, '').trim()], context, isConversation);
|
onCommand([message.body.replace(promptRegex, '').trim()], context, isConversation);
|
||||||
|
|
Loading…
Reference in New Issue