forked from pothtonswer/discordmuffin
Set GuildID on all Channels in READY.
This commit is contained in:
parent
a45e493e1f
commit
7eb0bd2aed
1 changed files with 7 additions and 0 deletions
7
state.go
7
state.go
|
@ -40,6 +40,13 @@ func (s *State) OnReady(r *Ready) error {
|
||||||
defer s.Unlock()
|
defer s.Unlock()
|
||||||
|
|
||||||
s.Ready = *r
|
s.Ready = *r
|
||||||
|
|
||||||
|
for _, g := range s.Guilds {
|
||||||
|
for _, c := range g.Channels {
|
||||||
|
c.GuildID = g.ID
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue