diff --git a/src/sendDirectMessage.ts b/src/sendDirectMessage.ts index 3a01821..9022180 100644 --- a/src/sendDirectMessage.ts +++ b/src/sendDirectMessage.ts @@ -9,6 +9,8 @@ export async function sendDirectMessage( userId: bigint, content: string | CreateMessage, ) { + if (typeof content === "string") content = { content }; + // GET CHANNEL ID FROM CACHE OR CREATE THE CHANNEL FOR THIS USER const cachedChannelId = dmChannelIds.get(userId); // IF ID IS CACHED SEND MESSAGE DIRECTLY