fixed ephemeral message flagging

This commit is contained in:
Lilith Schier 2026-08-20 18:09:32 +02:00
parent 0eec30fe82
commit 980db8afff

View file

@ -220,10 +220,11 @@ pub async fn roll(ctx: &Context, command: &CommandInteraction) -> anyhow::Result
.components(vec![CreateComponent::Container(CreateContainer::new(
text_components,
))])
.ephemeral(private)
// flags needs to be called before ephemeral for correct ordering
.flags(
MessageFlags::IS_COMPONENTS_V2 | MessageFlags::SUPPRESS_NOTIFICATIONS,
),
)
.ephemeral(private),
);
debug!("Returning response: {response:#?}");
@ -250,10 +251,11 @@ pub async fn roll(ctx: &Context, command: &CommandInteraction) -> anyhow::Result
CreateTextDisplay::new(err.to_string()),
)],
))])
.ephemeral(true)
// flags needs to be called before ephemeral for correct ordering
.flags(
MessageFlags::IS_COMPONENTS_V2 | MessageFlags::SUPPRESS_NOTIFICATIONS,
),
)
.ephemeral(true),
),
)
.await?