From f65d3ad14a0a119ca14e7882b185fc9cf2f81f6f Mon Sep 17 00:00:00 2001
From: Mihail Gribkov <61027276+Misha-133@users.noreply.github.com>
Date: Tue, 3 Sep 2024 14:26:45 +0300
Subject: [PATCH] =?UTF-8?q?use=20interaction=20method=20in=20`InteractionM?=
=?UTF-8?q?oduleBase.DeleteOriginalRespon=E2=80=A6=20(#2995)?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
* use interaction method in `InteractionModuleBase.DeleteOriginalResponseAsync()`
* ok this was even more scuffed
---
src/Discord.Net.Interactions/InteractionModuleBase.cs | 7 ++-----
1 file changed, 2 insertions(+), 5 deletions(-)
diff --git a/src/Discord.Net.Interactions/InteractionModuleBase.cs b/src/Discord.Net.Interactions/InteractionModuleBase.cs
index a6dfc60e..7b728150 100644
--- a/src/Discord.Net.Interactions/InteractionModuleBase.cs
+++ b/src/Discord.Net.Interactions/InteractionModuleBase.cs
@@ -109,11 +109,8 @@ namespace Discord.Interactions
=> Context.Interaction.ModifyOriginalResponseAsync(func, options);
///
- protected virtual async Task DeleteOriginalResponseAsync()
- {
- var response = await Context.Interaction.GetOriginalResponseAsync().ConfigureAwait(false);
- await response.DeleteAsync().ConfigureAwait(false);
- }
+ protected virtual Task DeleteOriginalResponseAsync()
+ => Context.Interaction.DeleteOriginalResponseAsync().ConfigureAwait(false);
///
protected virtual Task RespondWithModalAsync(Modal modal, RequestOptions options = null)