diff options
Diffstat (limited to 'DiscoBot/Auxiliary/Soundeffects.cs')
-rw-r--r-- | DiscoBot/Auxiliary/Soundeffects.cs | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/DiscoBot/Auxiliary/Soundeffects.cs b/DiscoBot/Auxiliary/Soundeffects.cs index d275eb4..d04b1c0 100644 --- a/DiscoBot/Auxiliary/Soundeffects.cs +++ b/DiscoBot/Auxiliary/Soundeffects.cs @@ -21,7 +21,7 @@ namespace DiscoBot.Auxiliary public static class SoundEffects { - public static Task Play(Sound s) + public static async Task Play(Sound s) { string url = string.Empty; int vol = 256; @@ -53,10 +53,11 @@ namespace DiscoBot.Auxiliary if (url != string.Empty) { - return Voice.SendAsync(url, vol); + await Task.Run(() => Voice.SendAsync(url, vol)); + return; } - return Dsa.GeneralContext.Channel.SendMessageAsync("Ton Existiert nicht"); + await Dsa.GeneralContext.Channel.SendMessageAsync("Ton Existiert nicht"); } } } |