X-Git-Url: https://git.localhorst.tv/?a=blobdiff_plain;f=app%2FTwitchBotCommands%2FBaseCommand.php;fp=app%2FTwitchBotCommands%2FBaseCommand.php;h=8cdc0ee61f01020790f5a0aa89a630ced86781ac;hb=51a752c7cce2465043dfb3d63a0152b64765b167;hp=881d4ed03e91c3611ac5fe7d65e4564be0154b8a;hpb=4b0f87a8b0683579c53c68f35b18e5d08c30b3b9;p=alttp.git diff --git a/app/TwitchBotCommands/BaseCommand.php b/app/TwitchBotCommands/BaseCommand.php index 881d4ed..8cdc0ee 100644 --- a/app/TwitchBotCommands/BaseCommand.php +++ b/app/TwitchBotCommands/BaseCommand.php @@ -10,12 +10,14 @@ abstract class BaseCommand { public static function resolve(TwitchBot $bot, TwitchBotCommand $cmd) { switch ($cmd->command) { + case 'chat': + return new ChatCommand($bot, $cmd); case 'join': return new JoinCommand($bot, $cmd); case 'part': return new PartCommand($bot, $cmd); default: - throw new Exception('unrecognized command'); + throw new \Exception('unrecognized command'); } }