Fix bug with Guild.by_category not showing some channels
If categories come after a child channel in the dictionary mapping for whatever reason, then the previous code would remove it from the mapping and set it to []. This commit aims to fix this.
This commit is contained in:
parent
45752ab354
commit
11f29890dc
@ -415,7 +415,7 @@ class Guild(Hashable):
|
||||
grouped = {}
|
||||
for channel in self._channels.values():
|
||||
if isinstance(channel, CategoryChannel):
|
||||
grouped[channel.id] = []
|
||||
grouped.setdefault(channel.id, [])
|
||||
continue
|
||||
|
||||
try:
|
||||
|
Loading…
x
Reference in New Issue
Block a user