[core] Allow case insensitive category matches

Signed-off-by: Knut Ahlers <knut@ahlers.me>
This commit is contained in:
Knut Ahlers 2023-05-11 14:42:32 +02:00
parent eee9e6594b
commit 63685ff5f2
Signed by: luzifer
GPG key ID: D91C3E91E4CAD6F5

View file

@ -6,6 +6,7 @@ import (
"encoding/json"
"fmt"
"net/http"
"strings"
"github.com/pkg/errors"
)
@ -75,7 +76,7 @@ func (c *Client) ModifyChannelInformation(ctx context.Context, broadcasterName s
default:
// Multiple matches: Search for exact one
for _, c := range categories {
if c.Name == *game {
if strings.EqualFold(c.Name, *game) {
gid := c.ID
data.GameID = &gid
break