From: Rudolf Polzer Date: Fri, 18 Feb 2022 00:02:59 +0000 (+0100) Subject: Fix handling of leave events due to kick. X-Git-Tag: xonotic-v0.8.5~26 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=f08345646f87314b163d282147bf0b95466eda16;p=xonotic%2Fxonotic.git Fix handling of leave events due to kick. --- diff --git a/misc/infrastructure/powerbot/bot.go b/misc/infrastructure/powerbot/bot.go index 2917c1d6..2f26ff00 100644 --- a/misc/infrastructure/powerbot/bot.go +++ b/misc/infrastructure/powerbot/bot.go @@ -199,9 +199,9 @@ func Run() (err error) { mem := evt.Content.AsMember() switch mem.Membership { case event.MembershipJoin: - handleJoin(eventTime(evt), evt.RoomID, evt.Sender, evt) + handleJoin(eventTime(evt), evt.RoomID, evt.StateKey, evt) case event.MembershipLeave: - handleLeave(eventTime(evt), evt.RoomID, evt.Sender, evt) + handleLeave(eventTime(evt), evt.RoomID, evt.StateKey, evt) default: // Ignore. } })