diff --git a/Controllers/WeatherForecastController.cs b/Controllers/WeatherForecastController.cs index fb3e3c8..8aac24b 100644 --- a/Controllers/WeatherForecastController.cs +++ b/Controllers/WeatherForecastController.cs @@ -29,7 +29,7 @@ namespace DiscordApp.Controllers await Console.Out.WriteLineAsync(guild.Name); var channel = guild.GetChannel(channelid) as ITextChannel; await Console.Out.WriteLineAsync(channel.Name); - var message = ((IReadOnlyCollection)channel.GetMessagesAsync().ToArrayAsync().Result).FirstOrDefault(k => k.Id == 1166079976446103602) as IUserMessage; + var message = (channel.GetMessagesAsync().FlattenAsync().Result).FirstOrDefault(k => k.Id == 1166079976446103602) as IUserMessage; await Console.Out.WriteLineAsync(message.Author.GlobalName); await message.ModifyAsync(func => {