diff --git a/twitch/badges.go b/twitch/badges.go index 3304362..8f8e118 100644 --- a/twitch/badges.go +++ b/twitch/badges.go @@ -60,6 +60,15 @@ func ParseBadgeLevels(m *irc.Message) BadgeCollection { out.Add(BadgeSubscriber, out.Get(BadgeFounder)) } + // In order to simplify queries and permissions add an + // implicit moderator badge to broadcasters as they have + // the same (and more) permissions than a moderator. So + // when allowing actions for moderators now broadcasters + // ill also be included. + if out.Has(BadgeBroadcaster) && !out.Has(BadgeModerator) { + out.Add(BadgeModerator, 1) + } + return out }