`fetchStarterMessage()` doesnt give me the first message of the thread

I am trying to get the first message associated with the thread. But the message object returned from the
fetchStarterMessage
is not giving me that. Below is the code I used to capture the thread creation.

module.exports = {
    name: Events.ThreadCreate,
    async execute(thread, newlyCreated) {
        if (!newlyCreated) return;
        if (!thread.isThread()) return;
        thread.awaitMessages().then(v => console.log(v)); // not printing anything
        var msg = await thread.fetchStarterMessage();
        console.log("msg: ", msg); // the message object has the content, but it is the title of the thread
    }
};


Can you please help me get the first message of the thread?
Was this page helpful?