𝑫𝒆𝒂𝒕𝒉
𝑫𝒆𝒂𝒕𝒉
DIAdiscord.js - Imagine an app
Created by peachii on 7/8/2024 in #djs-questions
TypeError: Cannot read properties of undefined (reading 'send')
First of all, you can use the get method instead of find
const channel = client.channels.cache.get("915481280538370059"); // -> K | undefined
const channel = client.channels.cache.get("915481280538370059"); // -> K | undefined
Keep in mind that the channel can be undefined if it wasn't found, so you can wrap the send method inside of a conditional
if (channel) { // If channel exists
channel.send({ embeds: [embed] }); // Sends the message
}
if (channel) { // If channel exists
channel.send({ embeds: [embed] }); // Sends the message
}
33 replies
DIAdiscord.js - Imagine an app
Created by CobaltΓ­x on 4/28/2024 in #djs-questions
ERREUR
@liveweeebΒ²
15 replies
DIAdiscord.js - Imagine an app
Created by CobaltΓ­x on 4/28/2024 in #djs-questions
ERREUR
Try removing the .addTimestamp from the embed and try again
15 replies
DIAdiscord.js - Imagine an app
Created by Marc-Anthony on 3/4/2024 in #djs-questions
Need Help for Fetch Ban CreatedAt
No problem sir
8 replies
DIAdiscord.js - Imagine an app
Created by Marc-Anthony on 3/4/2024 in #djs-questions
Need Help for Fetch Ban CreatedAt
I think you can't
8 replies
DIAdiscord.js - Imagine an app
Created by Marc-Anthony on 3/4/2024 in #djs-questions
Need Help for Fetch Ban CreatedAt
No description
8 replies
DIAdiscord.js - Imagine an app
Created by Marc-Anthony on 3/4/2024 in #djs-questions
Need Help for Fetch Ban CreatedAt
No description
8 replies