guildMemberRemove uncached members
So I am capturing guildMemberRemove events and I have the GuildMember and User partials selected.
When the member leaves the guild I have to check if the member had certain roles and if they did, update my database to say they are no longer have those rights.
The problem is if the member is not cached when the event fires, calling member.fetch() will return an Uknown Member APIError. I assume this is because the member no longer exists so you cannot fetch them.
What would be the best way to handle checking the roles of uncached members after they leave so i can update my database?
5 Replies
Unknown User•2y ago
Message Not Public
Sign In & Join Server To View
you can't really do this, since the member literally doesn't exist anymore
if they weren't cached before, you cannot get their data from when they were a member
The documentation says the only thing i can excpet from a partial is the ID, would the partial of a GuildMember contain the user object? or can i expect that won't be their either?
yes there should be a user
ok I will probably have to do the checks in the backend rather then the frontend then. Thanks