From: Daniel Karbach Date: Fri, 28 Jun 2024 15:27:24 +0000 (+0200) Subject: whispers X-Git-Url: https://git.localhorst.tv/?a=commitdiff_plain;h=af4f2e9450392e41e4a0bfb3247fe3b4435f03c7;p=alttp.git whispers --- diff --git a/app/Console/Commands/TwitchAuth.php b/app/Console/Commands/TwitchAuth.php index e46c118..4b185c6 100644 --- a/app/Console/Commands/TwitchAuth.php +++ b/app/Console/Commands/TwitchAuth.php @@ -33,7 +33,7 @@ class TwitchAuth extends Command { if (!$token) { $token = new TwitchToken(); $token->nick = $this->argument('nick'); - $token->scope = ['chat:read', 'chat:edit']; + $token->scope = ['chat:read', 'chat:edit', 'whispers:read', 'whispers:edit']; } $url = $token->getAuthUrl(); $this->line('Please visit '.$url); diff --git a/app/Models/ChatLog.php b/app/Models/ChatLog.php index cad1bfe..49a57c2 100644 --- a/app/Models/ChatLog.php +++ b/app/Models/ChatLog.php @@ -77,7 +77,7 @@ class ChatLog extends Model { return; } - if ($this->command == 'PRIVMSG') { + if ($this->command == 'PRIVMSG' || $this->command == 'WHISPER') { if (static::isKnownBot($this->nick)) { $this->type = 'bot'; } else if (substr($this->params[0], 0, 1) == '#') {