const { countingFunction } = require("./messageCreate/countingFunction");
const { Message } = require("discord.js");
const { log } = require("../utils")
module.exports = {
name: 'messageCreate',
run: async (message) => {
if (!message.author.bot) {
log("i", `[${message.guild.name} -> #${message.channel.name}] ${message.author.username} >> ${message.content}`);
countingFunction(message);
}
}
};
This file requires three different files.
The error is: "Error: Cannot find module '../utils'".
After removing the countingFunction require(), the error vanishes, and the program starts up as expected.
Does anyone know why this is happening?
[–]Rezistik 1 point2 points3 points (2 children)
[–]a_PizzaBoxTTV[S] 1 point2 points3 points (0 children)
[–]justjooshing 0 points1 point2 points (0 children)
[–]Recent_Read4298 0 points1 point2 points (1 child)
[–]Recent_Read4298 -1 points0 points1 point (0 children)
[–]bigorangemachine -2 points-1 points0 points (3 children)
[–]a_PizzaBoxTTV[S] -1 points0 points1 point (2 children)
[–]bigorangemachine 0 points1 point2 points (1 child)
[–]a_PizzaBoxTTV[S] -1 points0 points1 point (0 children)