Swocks
Swocks
DIAdiscord.js - Imagine an app
Created by Swocks on 9/16/2023 in #djs-questions
"Supplied parameter is not a User nor a Role", but it is?
I'm running this code:
// Make Visible to Claimant Only
await channel.permissionOverwrites.create([
{ // Staff Member Who Claimed
id: interaction.user.id,
allow: [PermissionsBitField.Flags.ViewChannel],
type: OverwriteType.Member
}
])
// Make Visible to Claimant Only
await channel.permissionOverwrites.create([
{ // Staff Member Who Claimed
id: interaction.user.id,
allow: [PermissionsBitField.Flags.ViewChannel],
type: OverwriteType.Member
}
])
However I get the error: TypeError [InvalidType]: Supplied parameter is not a User nor a Role. It is inside of an interaction code, and console.logging the interaction.user.id is COMPLETELY valid, I've even tried removing it from the array. Why am I getting this error for a valid User/role?
2 replies