Skip to main content

Function: isGuildMember()

isGuildMember(member: APIGuildMember | APIInteractionGuildMember | APIInteractionDataResolvedGuildMember | GuildMember | Nullish): member is GuildMember

Checks whether a given member is an instance of GuildMember, and not APIInteractionGuildMember, APIGuildMember, or Nullish

Parameters

ParameterTypeDescription
memberAPIGuildMember | APIInteractionGuildMember | APIInteractionDataResolvedGuildMember | GuildMember | NullishThe member to check

Returns

member is GuildMember

true if the member is an instance of GuildMember, false otherwise.

Defined in

projects/utilities/packages/discord.js-utilities/src/lib/type-guards.ts:305