diff --git a/src/Discord.Net.Interactions/Extensions/IDiscordInteractionExtensions.cs b/src/Discord.Net.Interactions/Extensions/IDiscordInteractionExtensions.cs
index 5c379cf42..ebb744533 100644
--- a/src/Discord.Net.Interactions/Extensions/IDiscordInteractionExtensions.cs
+++ b/src/Discord.Net.Interactions/Extensions/IDiscordInteractionExtensions.cs
@@ -10,9 +10,10 @@ namespace Discord.Interactions
///
/// Type of the implementation.
/// The interaction to respond to.
+ /// Delegate that can be used to modify the modal.
/// The request options for this request.
/// A task that represents the asynchronous operation of responding to the interaction.
- public static async Task RespondWithModalAsync(this IDiscordInteraction interaction, string customId, RequestOptions options = null)
+ public static async Task RespondWithModalAsync(this IDiscordInteraction interaction, string customId, Action modifyModal = null, RequestOptions options = null)
where T : class, IModal
{
if (!ModalUtils.TryGet(out var modalInfo))
@@ -31,6 +32,9 @@ namespace Discord.Interactions
throw new InvalidOperationException($"{input.GetType().FullName} isn't a valid component info class");
}
+ if (modifyModal is not null)
+ modifyModal(builder);
+
await interaction.RespondWithModalAsync(builder.Build(), options).ConfigureAwait(false);
}
}