Make !calc properly broadcast as a !math alias (#8950)

This commit is contained in:
Alexander B 2022-10-24 18:09:55 -05:00 committed by GitHub
parent 906d5b2692
commit cdc5fe0aa6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1737,7 +1737,7 @@ export const commands: Chat.ChatCommands = {
randbatscalc: 'calc',
rcalc: 'calc',
calc(target, room, user, connection, cmd) {
if (cmd === 'calc' && target) return this.parse(`/math ${target}`);
if (cmd === 'calc' && target) return this.run('calculate');
if (!this.runBroadcast()) return;
const DEFAULT_CALC_COMMANDS = ['honkalculator', 'honkocalc'];
const RANDOMS_CALC_COMMANDS = ['randomscalc', 'randbatscalc', 'rcalc'];