Skip to main content

Function: isMessageInstance()

isMessageInstance(message: APIMessage | Message): message is Message

Defined in: projects/utilities/packages/discord.js-utilities/src/lib/type-guards.ts:234

Checks whether a given message is an instance of Message, and not APIMessage

Parameters

ParameterTypeDescription
messageAPIMessage | MessageThe message to check

Returns

message is Message

true if the message is an instance of Message, false otherwise.