diff --git a/TeamOctolings.Octobot/Commands/AboutCommandGroup.cs b/TeamOctolings.Octobot/Commands/AboutCommandGroup.cs index dbb8b12..4575259 100644 --- a/TeamOctolings.Octobot/Commands/AboutCommandGroup.cs +++ b/TeamOctolings.Octobot/Commands/AboutCommandGroup.cs @@ -131,7 +131,7 @@ private async Task SendAboutBotAsync(IUser bot, Snowflake guildId, Cance return await _feedback.SendContextualEmbedResultAsync(embed, new FeedbackMessageOptions(MessageComponents: new[] { - new ActionRowComponent(new[] { repositoryButton, wikiButton, issuesButton }) + new ActionRowComponent([repositoryButton, wikiButton, issuesButton]) }), ct); } } diff --git a/TeamOctolings.Octobot/Commands/BanCommandGroup.cs b/TeamOctolings.Octobot/Commands/BanCommandGroup.cs index 69be80f..1d6b26c 100644 --- a/TeamOctolings.Octobot/Commands/BanCommandGroup.cs +++ b/TeamOctolings.Octobot/Commands/BanCommandGroup.cs @@ -62,7 +62,7 @@ public BanCommandGroup(AccessControlService access, IDiscordRestChannelAPI chann /// /// /// A feedback sending result which may or may not have succeeded. A successful result does not mean that the user - /// was banned and vice-versa. + /// was banned and vice versa. /// /// [Command("ban", "бан")] @@ -219,7 +219,7 @@ var interactionResult /// /// /// A feedback sending result which may or may not have succeeded. A successful result does not mean that the user - /// was unbanned and vice-versa. + /// was unbanned and vice versa. /// /// /// diff --git a/TeamOctolings.Octobot/Commands/ClearCommandGroup.cs b/TeamOctolings.Octobot/Commands/ClearCommandGroup.cs index 7c1b516..7f29581 100644 --- a/TeamOctolings.Octobot/Commands/ClearCommandGroup.cs +++ b/TeamOctolings.Octobot/Commands/ClearCommandGroup.cs @@ -51,7 +51,7 @@ public ClearCommandGroup( /// The user whose messages will be cleared. /// /// A feedback sending result which may or may not have succeeded. A successful result does not mean that any messages - /// were cleared and vice-versa. + /// were cleared and vice versa. /// [Command("clear", "очистить")] [DiscordDefaultMemberPermissions(DiscordPermission.ManageMessages)] diff --git a/TeamOctolings.Octobot/Commands/Events/ErrorLoggingPostExecutionEvent.cs b/TeamOctolings.Octobot/Commands/Events/ErrorLoggingPostExecutionEvent.cs index 7409d3b..ff7339f 100644 --- a/TeamOctolings.Octobot/Commands/Events/ErrorLoggingPostExecutionEvent.cs +++ b/TeamOctolings.Octobot/Commands/Events/ErrorLoggingPostExecutionEvent.cs @@ -81,7 +81,7 @@ public async Task AfterExecutionAsync( return ResultExtensions.FromError(await _feedback.SendContextualEmbedResultAsync(embed, new FeedbackMessageOptions(MessageComponents: new[] { - new ActionRowComponent(new[] { issuesButton }) + new ActionRowComponent([issuesButton]) }), ct) ); } diff --git a/TeamOctolings.Octobot/Commands/KickCommandGroup.cs b/TeamOctolings.Octobot/Commands/KickCommandGroup.cs index a8fea2a..3011375 100644 --- a/TeamOctolings.Octobot/Commands/KickCommandGroup.cs +++ b/TeamOctolings.Octobot/Commands/KickCommandGroup.cs @@ -57,7 +57,7 @@ public KickCommandGroup(AccessControlService access, IDiscordRestChannelAPI chan /// /// /// A feedback sending result which may or may not have succeeded. A successful result does not mean that the member - /// was kicked and vice-versa. + /// was kicked and vice versa. /// [Command("kick", "кик")] [DiscordDefaultMemberPermissions(DiscordPermission.ManageMessages)] diff --git a/TeamOctolings.Octobot/Commands/MuteCommandGroup.cs b/TeamOctolings.Octobot/Commands/MuteCommandGroup.cs index 46e8d84..5dce0b6 100644 --- a/TeamOctolings.Octobot/Commands/MuteCommandGroup.cs +++ b/TeamOctolings.Octobot/Commands/MuteCommandGroup.cs @@ -59,7 +59,7 @@ public MuteCommandGroup(AccessControlService access, ICommandContext context, IF /// /// /// A feedback sending result which may or may not have succeeded. A successful result does not mean that the member - /// was muted and vice-versa. + /// was muted and vice versa. /// /// [Command("mute", "мут")] @@ -235,7 +235,7 @@ private async Task TimeoutUserAsync( /// /// /// A feedback sending result which may or may not have succeeded. A successful result does not mean that the member - /// was unmuted and vice-versa. + /// was unmuted and vice versa. /// /// /// diff --git a/TeamOctolings.Octobot/Data/Reminder.cs b/TeamOctolings.Octobot/Data/Reminder.cs index c3936da..40f29e1 100644 --- a/TeamOctolings.Octobot/Data/Reminder.cs +++ b/TeamOctolings.Octobot/Data/Reminder.cs @@ -1,9 +1,9 @@ namespace TeamOctolings.Octobot.Data; -public struct Reminder +public sealed record Reminder { - public DateTimeOffset At { get; init; } - public string Text { get; init; } - public ulong ChannelId { get; init; } - public ulong MessageId { get; init; } + public required DateTimeOffset At { get; init; } + public required string Text { get; init; } + public required ulong ChannelId { get; init; } + public required ulong MessageId { get; init; } } diff --git a/TeamOctolings.Octobot/Responders/GuildLoadedResponder.cs b/TeamOctolings.Octobot/Responders/GuildLoadedResponder.cs index b420db2..b24ef0b 100644 --- a/TeamOctolings.Octobot/Responders/GuildLoadedResponder.cs +++ b/TeamOctolings.Octobot/Responders/GuildLoadedResponder.cs @@ -120,6 +120,6 @@ private async Task SendDataLoadFailed(IGuild guild, GuildData data, IUse ); return await _channelApi.CreateMessageWithEmbedResultAsync(channel, embedResult: errorEmbed, - components: new[] { new ActionRowComponent(new[] { issuesButton }) }, ct: ct); + components: new[] { new ActionRowComponent([issuesButton]) }, ct: ct); } } diff --git a/TeamOctolings.Octobot/Services/Update/ScheduledEventUpdateService.cs b/TeamOctolings.Octobot/Services/Update/ScheduledEventUpdateService.cs index ef145aa..389a6a8 100644 --- a/TeamOctolings.Octobot/Services/Update/ScheduledEventUpdateService.cs +++ b/TeamOctolings.Octobot/Services/Update/ScheduledEventUpdateService.cs @@ -229,7 +229,7 @@ private async Task SendScheduledEventCreatedMessage( return await _channelApi.CreateMessageWithEmbedResultAsync( GuildSettings.EventNotificationChannel.Get(settings), roleMention, embedResult: embed, - components: new[] { new ActionRowComponent(new[] { button }) }, ct: ct); + components: new[] { new ActionRowComponent([button]) }, ct: ct); } private static Result GetExternalScheduledEventCreatedEmbedDescription(