This is an unrelated problem to the other post, as I’m able to use the following code when it is started, but I’m unable to go through the bot using the same code with the test stuff commented.
After I set bindIpAll: true in the mongod.service file, as mentioned in my other post, I get the exact same error as before only when using the Discord bot. However, whenever I run the following code as a standalone file, it works perfectly fine.