Commit 0ae32dcb authored by George Peter Banyard's avatar George Peter Banyard
Browse files

Implemented a no message send option.

To trigger it null must be returned in the reply function.
parent c32d1794
Loading
Loading
Loading
Loading
+9 −7
Original line number Diff line number Diff line
@@ -357,6 +357,7 @@ DiscordBotClient.on('message', async message =>
    };

    let replyData =  await reply();
    if (replyData !== null) {
        if (replyData.noDelete !== true) {
            message.delete();
        }
@@ -365,6 +366,7 @@ DiscordBotClient.on('message', async message =>
        } else {
            channel.send(replyData.message).catch(e => console.error(e));
        }
    }
});

/**