Check if the member exists before creating a GuildMember
This commit is contained in:
parent
68e42b8b36
commit
a7b300d233
|
@ -144,7 +144,8 @@ export class Guild {
|
|||
}
|
||||
|
||||
getMember(id) {
|
||||
return new GuildMember(Modules.GuildMemberStore.getMember(this.id, id));
|
||||
const member = Modules.GuildMemberStore.getMember(this.id, id);
|
||||
if (member) return new GuildMember(member, this.id);
|
||||
}
|
||||
|
||||
isMember(id) {
|
||||
|
|
Loading…
Reference in New Issue