TypeError: Cannot read properties of undefined (reading 'send')

i did find a few posts on this error but no amount of research or looking through documentation has fixed my issue.

basically, im receiving this error when i try to send a message from my discord bot to a specific channel using client.channels.cashe.get

problem code:

const channel = client.channels.cache.find(channel => channel.id === "915481280538370059");

await interaction.reply({content: 'User kicked :peachcord_checkmark:', ephemeral: true});

await channel.send({embeds: [embed]})

interaction.guild.members.kick(user);

the problem is said to be with this line:

await channel.send({embeds: [embed]})

the previous code is not necessary as its just my slash command builder and the issue is with the method im trying to use to send this message, but if its needed i can provide.

if possible i would greatly appreciate some help ;-;
Was this page helpful?