Skip to content

Commit

Permalink
fix(InteractionsSelfRoleManager): avoid non-unique custom_ids
Browse files Browse the repository at this point in the history
  • Loading branch information
Tinaël Devresse committed Sep 18, 2024
1 parent 5692373 commit d40bebd
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/InteractionsSelfRoleManager.ts
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ export class InteractionsSelfRoleManager extends SelfRoleManager {
new StringSelectMenuBuilder({
min_values: minValues,
max_values: maxValues,
custom_id: `${packagePrefix}${selectMenuPrefix}roles`,
custom_id: `${packagePrefix}${selectMenuPrefix}roles-${channel.id}`,
placeholder:
channelOptions.selectMenu?.placeholder ??
"Select a role",
Expand All @@ -183,7 +183,7 @@ export class InteractionsSelfRoleManager extends SelfRoleManager {
new ActionRowBuilder<ButtonBuilder>().addComponents(
new ButtonBuilder()
.setCustomId(
`${packagePrefix}${selectMenuPrefix}reset`,
`${packagePrefix}${selectMenuPrefix}reset-${channel.id}`,
)
.setEmoji(
channelOptions.selectMenu.resetButton
Expand Down

0 comments on commit d40bebd

Please sign in to comment.