Skip to content

Commit 778d4f6

Browse files
committed
BugFix - get_members raised AttributeError because no clan found in cache.
- Bit of a bandaid solution provided, function might need a refactor later on.
1 parent b8436dc commit 778d4f6

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

coc/client.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -397,7 +397,8 @@ async def get_members(
397397
if fetch is False:
398398
return
399399
else:
400-
return clan.members
400+
if clan:
401+
return clan.members
401402

402403
data = await self.http.get_clan(clan_tag)
403404
clan = SearchClan(data=data, http=self.http)

0 commit comments

Comments
 (0)