diff --git a/src/NadekoBot/Bot.cs b/src/NadekoBot/Bot.cs index 869dc5879..73f14e002 100644 --- a/src/NadekoBot/Bot.cs +++ b/src/NadekoBot/Bot.cs @@ -1,17 +1,9 @@ -using Discord; -using Discord.Commands; -using Discord.WebSocket; -using Microsoft.Extensions.DependencyInjection; -using NadekoBot.Common; -using NadekoBot.Services; +using Microsoft.Extensions.DependencyInjection; using NadekoBot.Services.Database.Models; using NadekoBot.Extensions; using System.Collections.Immutable; using System.Diagnostics; -using System.Net.Http; using System.Reflection; -using System.Threading.Tasks; -using Discord.Net; using NadekoBot.Common.ModuleBehaviors; using NadekoBot.Common.Configs; using NadekoBot.Db; @@ -82,11 +74,11 @@ public sealed class Bot { var startingGuildIdList = GetCurrentGuildIds(); var sw = Stopwatch.StartNew(); - var _bot = Client.CurrentUser; + var bot = Client.CurrentUser; using (var uow = _db.GetDbContext()) { - uow.EnsureUserCreated(_bot.Id, _bot.Username, _bot.Discriminator, _bot.AvatarId); + uow.EnsureUserCreated(bot.Id, bot.Username, bot.Discriminator, bot.AvatarId); AllGuildConfigs = uow.GuildConfigs.GetAllGuildConfigs(startingGuildIdList).ToImmutableArray(); } @@ -199,7 +191,7 @@ public sealed class Bot } var filteredTypes = allTypes .Where(x => x.IsSubclassOf(typeof(TypeReader)) - && x.BaseType.GetGenericArguments().Length > 0 + && x.BaseType?.GetGenericArguments().Length > 0 && !x.IsAbstract); var toReturn = new List(); @@ -207,6 +199,8 @@ public sealed class Bot { var x = (TypeReader)ActivatorUtilities.CreateInstance(Services, ft); var baseType = ft.BaseType; + if (baseType is null) + continue; var typeArgs = baseType.GetGenericArguments(); _commandService.AddTypeReader(typeArgs[0], x); toReturn.Add(x); diff --git a/src/NadekoBot/Common/AsyncLazy.cs b/src/NadekoBot/Common/AsyncLazy.cs index d3a45812f..4687ef1ce 100644 --- a/src/NadekoBot/Common/AsyncLazy.cs +++ b/src/NadekoBot/Common/AsyncLazy.cs @@ -1,5 +1,4 @@ using System.Runtime.CompilerServices; -using System.Threading.Tasks; namespace NadekoBot.Common; diff --git a/src/NadekoBot/Common/Attributes/Aliases.cs b/src/NadekoBot/Common/Attributes/Aliases.cs index 8d5c1be52..9b7856965 100644 --- a/src/NadekoBot/Common/Attributes/Aliases.cs +++ b/src/NadekoBot/Common/Attributes/Aliases.cs @@ -1,5 +1,4 @@ using System.Runtime.CompilerServices; -using Discord.Commands; namespace NadekoBot.Common.Attributes; diff --git a/src/NadekoBot/Common/Attributes/BotPerm.cs b/src/NadekoBot/Common/Attributes/BotPerm.cs index d1f3ffc7e..837d7e408 100644 --- a/src/NadekoBot/Common/Attributes/BotPerm.cs +++ b/src/NadekoBot/Common/Attributes/BotPerm.cs @@ -1,6 +1,4 @@ -using Discord.Commands; - -namespace Discord; +namespace Discord; public class BotPermAttribute : RequireBotPermissionAttribute { diff --git a/src/NadekoBot/Common/Attributes/CommandNameLoadHelper.cs b/src/NadekoBot/Common/Attributes/CommandNameLoadHelper.cs index bf4a5b067..56bdc514e 100644 --- a/src/NadekoBot/Common/Attributes/CommandNameLoadHelper.cs +++ b/src/NadekoBot/Common/Attributes/CommandNameLoadHelper.cs @@ -1,6 +1,4 @@ -using System.IO; - -namespace NadekoBot.Common.Attributes; +namespace NadekoBot.Common.Attributes; public static class CommandNameLoadHelper { diff --git a/src/NadekoBot/Common/Attributes/Description.cs b/src/NadekoBot/Common/Attributes/Description.cs index 44b6bd525..5286b6d27 100644 --- a/src/NadekoBot/Common/Attributes/Description.cs +++ b/src/NadekoBot/Common/Attributes/Description.cs @@ -1,6 +1,4 @@ -using Discord.Commands; - -namespace NadekoBot.Common.Attributes; +namespace NadekoBot.Common.Attributes; [AttributeUsage(AttributeTargets.Method)] public sealed class DescriptionAttribute : SummaryAttribute diff --git a/src/NadekoBot/Common/Attributes/NadekoCommand.cs b/src/NadekoBot/Common/Attributes/NadekoCommand.cs index a61059bf9..7e15fa8b5 100644 --- a/src/NadekoBot/Common/Attributes/NadekoCommand.cs +++ b/src/NadekoBot/Common/Attributes/NadekoCommand.cs @@ -1,5 +1,4 @@ using System.Runtime.CompilerServices; -using Discord.Commands; namespace NadekoBot.Common.Attributes; diff --git a/src/NadekoBot/Common/Attributes/NadekoModuleAttribute.cs b/src/NadekoBot/Common/Attributes/NadekoModuleAttribute.cs index f51815d68..5fb97dbee 100644 --- a/src/NadekoBot/Common/Attributes/NadekoModuleAttribute.cs +++ b/src/NadekoBot/Common/Attributes/NadekoModuleAttribute.cs @@ -1,6 +1,4 @@ -using Discord.Commands; - -namespace NadekoBot.Common.Attributes; +namespace NadekoBot.Common.Attributes; [AttributeUsage(AttributeTargets.Class)] sealed class NadekoModuleAttribute : GroupAttribute diff --git a/src/NadekoBot/Common/Attributes/OwnerOnlyAttribute.cs b/src/NadekoBot/Common/Attributes/OwnerOnlyAttribute.cs index ae9d884b7..3c88919ea 100644 --- a/src/NadekoBot/Common/Attributes/OwnerOnlyAttribute.cs +++ b/src/NadekoBot/Common/Attributes/OwnerOnlyAttribute.cs @@ -1,8 +1,5 @@ -using System.Threading.Tasks; -using Discord.Commands; -using Microsoft.Extensions.DependencyInjection; +using Microsoft.Extensions.DependencyInjection; using NadekoBot.Extensions; -using NadekoBot.Services; namespace NadekoBot.Common.Attributes; diff --git a/src/NadekoBot/Common/Attributes/Ratelimit.cs b/src/NadekoBot/Common/Attributes/Ratelimit.cs index 5078e2959..b5b9cdbe7 100644 --- a/src/NadekoBot/Common/Attributes/Ratelimit.cs +++ b/src/NadekoBot/Common/Attributes/Ratelimit.cs @@ -1,7 +1,4 @@ -using Discord.Commands; -using NadekoBot.Services; -using System.Threading.Tasks; -using Microsoft.Extensions.DependencyInjection; +using Microsoft.Extensions.DependencyInjection; namespace NadekoBot.Common.Attributes; diff --git a/src/NadekoBot/Common/Attributes/Usage.cs b/src/NadekoBot/Common/Attributes/Usage.cs index 7e3f24d4b..96e30eb0a 100644 --- a/src/NadekoBot/Common/Attributes/Usage.cs +++ b/src/NadekoBot/Common/Attributes/Usage.cs @@ -1,6 +1,4 @@ -using Discord.Commands; - -namespace NadekoBot.Common.Attributes; +namespace NadekoBot.Common.Attributes; [AttributeUsage(AttributeTargets.Method)] public sealed class UsageAttribute : RemarksAttribute diff --git a/src/NadekoBot/Common/Attributes/UserPerm.cs b/src/NadekoBot/Common/Attributes/UserPerm.cs index ee6b0e701..5e10f6a0a 100644 --- a/src/NadekoBot/Common/Attributes/UserPerm.cs +++ b/src/NadekoBot/Common/Attributes/UserPerm.cs @@ -1,6 +1,4 @@ -using System.Threading.Tasks; -using Discord.Commands; -using Microsoft.Extensions.DependencyInjection; +using Microsoft.Extensions.DependencyInjection; using NadekoBot.Modules.Administration.Services; namespace Discord; diff --git a/src/NadekoBot/Common/Collections/ConcurrentHashSet.cs b/src/NadekoBot/Common/Collections/ConcurrentHashSet.cs index 17538d18f..56fb18043 100644 --- a/src/NadekoBot/Common/Collections/ConcurrentHashSet.cs +++ b/src/NadekoBot/Common/Collections/ConcurrentHashSet.cs @@ -3,7 +3,6 @@ using System.Collections; using System.Diagnostics; -using System.Threading; namespace NadekoBot.Common.Collections; diff --git a/src/NadekoBot/Common/DownloadTracker.cs b/src/NadekoBot/Common/DownloadTracker.cs index a8142a8ab..e60c33496 100644 --- a/src/NadekoBot/Common/DownloadTracker.cs +++ b/src/NadekoBot/Common/DownloadTracker.cs @@ -1,10 +1,4 @@ -using NadekoBot.Services; -using System.Collections.Concurrent; -using System.Threading; -using System.Threading.Tasks; -using Discord; - -namespace NadekoBot.Common; +namespace NadekoBot.Common; public class DownloadTracker : INService { diff --git a/src/NadekoBot/Common/Extensions/IBotCredentialsExtensions.cs b/src/NadekoBot/Common/Extensions/IBotCredentialsExtensions.cs index 78ef98d1c..560a8fde8 100644 --- a/src/NadekoBot/Common/Extensions/IBotCredentialsExtensions.cs +++ b/src/NadekoBot/Common/Extensions/IBotCredentialsExtensions.cs @@ -1,6 +1,4 @@ -using Discord; - -namespace NadekoBot.Extensions; +namespace NadekoBot.Extensions; public static class BotCredentialsExtensions { diff --git a/src/NadekoBot/Common/Extensions/ServiceCollectionExtensions.cs b/src/NadekoBot/Common/Extensions/ServiceCollectionExtensions.cs index bd465b30d..8d40cfd1e 100644 --- a/src/NadekoBot/Common/Extensions/ServiceCollectionExtensions.cs +++ b/src/NadekoBot/Common/Extensions/ServiceCollectionExtensions.cs @@ -1,8 +1,6 @@ using System.Reflection; using Microsoft.Extensions.DependencyInjection; -using NadekoBot.Common; using NadekoBot.Modules.Music; -using NadekoBot.Services; using NadekoBot.Modules.Music.Resolvers; using NadekoBot.Modules.Music.Services; using StackExchange.Redis; diff --git a/src/NadekoBot/Common/IBotCredentials.cs b/src/NadekoBot/Common/IBotCredentials.cs index 6621aa4cb..de1106b78 100644 --- a/src/NadekoBot/Common/IBotCredentials.cs +++ b/src/NadekoBot/Common/IBotCredentials.cs @@ -1,6 +1,4 @@ -using NadekoBot.Common; - -namespace NadekoBot; +namespace NadekoBot; public interface IBotCredentials { diff --git a/src/NadekoBot/Common/IEmbedBuilder.cs b/src/NadekoBot/Common/IEmbedBuilder.cs index c9fd0f500..bf47f8bb4 100644 --- a/src/NadekoBot/Common/IEmbedBuilder.cs +++ b/src/NadekoBot/Common/IEmbedBuilder.cs @@ -1,6 +1,4 @@ -using Discord; - -namespace NadekoBot; +namespace NadekoBot; public interface IEmbedBuilder { diff --git a/src/NadekoBot/Common/LoginErrorHandler.cs b/src/NadekoBot/Common/LoginErrorHandler.cs index 122a01c74..b380a378a 100644 --- a/src/NadekoBot/Common/LoginErrorHandler.cs +++ b/src/NadekoBot/Common/LoginErrorHandler.cs @@ -1,6 +1,5 @@ using System.Net; using System.Runtime.CompilerServices; -using Discord.Net; namespace NadekoBot.Common; diff --git a/src/NadekoBot/Common/ModuleBehaviors/IEarlyBehavior.cs b/src/NadekoBot/Common/ModuleBehaviors/IEarlyBehavior.cs index 032f47630..a569becf7 100644 --- a/src/NadekoBot/Common/ModuleBehaviors/IEarlyBehavior.cs +++ b/src/NadekoBot/Common/ModuleBehaviors/IEarlyBehavior.cs @@ -1,7 +1,4 @@ -using System.Threading.Tasks; -using Discord; - -namespace NadekoBot.Common.ModuleBehaviors; +namespace NadekoBot.Common.ModuleBehaviors; /// /// Implemented by modules which block execution before anything is executed diff --git a/src/NadekoBot/Common/ModuleBehaviors/IINputTransformer.cs b/src/NadekoBot/Common/ModuleBehaviors/IINputTransformer.cs index 552eba1ec..510c76b1a 100644 --- a/src/NadekoBot/Common/ModuleBehaviors/IINputTransformer.cs +++ b/src/NadekoBot/Common/ModuleBehaviors/IINputTransformer.cs @@ -1,7 +1,4 @@ -using System.Threading.Tasks; -using Discord; - -namespace NadekoBot.Common.ModuleBehaviors; +namespace NadekoBot.Common.ModuleBehaviors; public interface IInputTransformer { diff --git a/src/NadekoBot/Common/ModuleBehaviors/ILateBlocker.cs b/src/NadekoBot/Common/ModuleBehaviors/ILateBlocker.cs index af9ad2a48..516335a5c 100644 --- a/src/NadekoBot/Common/ModuleBehaviors/ILateBlocker.cs +++ b/src/NadekoBot/Common/ModuleBehaviors/ILateBlocker.cs @@ -1,7 +1,4 @@ -using System.Threading.Tasks; -using Discord.Commands; - -namespace NadekoBot.Common.ModuleBehaviors; +namespace NadekoBot.Common.ModuleBehaviors; public interface ILateBlocker { diff --git a/src/NadekoBot/Common/ModuleBehaviors/ILateExecutor.cs b/src/NadekoBot/Common/ModuleBehaviors/ILateExecutor.cs index a10688c03..c7d826a6e 100644 --- a/src/NadekoBot/Common/ModuleBehaviors/ILateExecutor.cs +++ b/src/NadekoBot/Common/ModuleBehaviors/ILateExecutor.cs @@ -1,7 +1,4 @@ -using System.Threading.Tasks; -using Discord; - -namespace NadekoBot.Common.ModuleBehaviors; +namespace NadekoBot.Common.ModuleBehaviors; /// /// Last thing to be executed, won't stop further executions diff --git a/src/NadekoBot/Common/ModuleBehaviors/IReadyExecutor.cs b/src/NadekoBot/Common/ModuleBehaviors/IReadyExecutor.cs index 6c05c1f29..82dd566b5 100644 --- a/src/NadekoBot/Common/ModuleBehaviors/IReadyExecutor.cs +++ b/src/NadekoBot/Common/ModuleBehaviors/IReadyExecutor.cs @@ -1,6 +1,4 @@ -using System.Threading.Tasks; - -namespace NadekoBot.Common.ModuleBehaviors; +namespace NadekoBot.Common.ModuleBehaviors; /// /// All services which need to execute something after diff --git a/src/NadekoBot/Common/NadekoModule.cs b/src/NadekoBot/Common/NadekoModule.cs index b533c7df1..d54735527 100644 --- a/src/NadekoBot/Common/NadekoModule.cs +++ b/src/NadekoBot/Common/NadekoModule.cs @@ -1,10 +1,5 @@ -using Discord; -using Discord.Commands; -using Discord.WebSocket; -using NadekoBot.Services; -using NadekoBot.Extensions; +using NadekoBot.Extensions; using System.Globalization; -using System.Threading.Tasks; namespace NadekoBot.Modules; diff --git a/src/NadekoBot/Common/NoPublicBotPrecondition.cs b/src/NadekoBot/Common/NoPublicBotPrecondition.cs index bd479f5fc..855f02e2a 100644 --- a/src/NadekoBot/Common/NoPublicBotPrecondition.cs +++ b/src/NadekoBot/Common/NoPublicBotPrecondition.cs @@ -1,7 +1,4 @@ -using System.Threading.Tasks; -using Discord.Commands; - -namespace NadekoBot.Common; +namespace NadekoBot.Common; [AttributeUsage(AttributeTargets.Method | AttributeTargets.Class)] public sealed class NoPublicBotAttribute : PreconditionAttribute diff --git a/src/NadekoBot/Common/PubSub/EventPubSub.cs b/src/NadekoBot/Common/PubSub/EventPubSub.cs index 521030700..e4cc2182b 100644 --- a/src/NadekoBot/Common/PubSub/EventPubSub.cs +++ b/src/NadekoBot/Common/PubSub/EventPubSub.cs @@ -1,6 +1,4 @@ -using System.Threading.Tasks; - -namespace NadekoBot.Common; +namespace NadekoBot.Common; public class EventPubSub : IPubSub { diff --git a/src/NadekoBot/Common/PubSub/IPubSub.cs b/src/NadekoBot/Common/PubSub/IPubSub.cs index cbdba3fcd..aac56a65c 100644 --- a/src/NadekoBot/Common/PubSub/IPubSub.cs +++ b/src/NadekoBot/Common/PubSub/IPubSub.cs @@ -1,6 +1,4 @@ -using System.Threading.Tasks; - -namespace NadekoBot.Common; +namespace NadekoBot.Common; public interface IPubSub { diff --git a/src/NadekoBot/Common/PubSub/RedisPubSub.cs b/src/NadekoBot/Common/PubSub/RedisPubSub.cs index aabe1cef5..8c699210a 100644 --- a/src/NadekoBot/Common/PubSub/RedisPubSub.cs +++ b/src/NadekoBot/Common/PubSub/RedisPubSub.cs @@ -1,5 +1,4 @@ -using System.Threading.Tasks; -using NadekoBot.Extensions; +using NadekoBot.Extensions; using StackExchange.Redis; namespace NadekoBot.Common; diff --git a/src/NadekoBot/Common/Replacements/ReplacementBuilder.cs b/src/NadekoBot/Common/Replacements/ReplacementBuilder.cs index a012e4354..362b538d9 100644 --- a/src/NadekoBot/Common/Replacements/ReplacementBuilder.cs +++ b/src/NadekoBot/Common/Replacements/ReplacementBuilder.cs @@ -1,12 +1,8 @@ -using Discord; -using Discord.Commands; -using Discord.WebSocket; -using NadekoBot.Extensions; +using NadekoBot.Extensions; using NadekoBot.Modules.Administration.Services; -using System.Collections.Concurrent; using System.Text.RegularExpressions; -namespace NadekoBot.Common.Replacements; +namespace NadekoBot.Common; public class ReplacementBuilder { diff --git a/src/NadekoBot/Common/Replacements/Replacer.cs b/src/NadekoBot/Common/Replacements/Replacer.cs index 03c162391..8e8dc31aa 100644 --- a/src/NadekoBot/Common/Replacements/Replacer.cs +++ b/src/NadekoBot/Common/Replacements/Replacer.cs @@ -1,6 +1,6 @@ using System.Text.RegularExpressions; -namespace NadekoBot.Common.Replacements; +namespace NadekoBot.Common; public class Replacer { diff --git a/src/NadekoBot/Common/SmartText/SmartEmbedText.cs b/src/NadekoBot/Common/SmartText/SmartEmbedText.cs index 564b7a8e0..ddc230f98 100644 --- a/src/NadekoBot/Common/SmartText/SmartEmbedText.cs +++ b/src/NadekoBot/Common/SmartText/SmartEmbedText.cs @@ -1,5 +1,4 @@ -using Discord; -using NadekoBot.Extensions; +using NadekoBot.Extensions; namespace NadekoBot; diff --git a/src/NadekoBot/Common/SocketMessageEventWrapper.cs b/src/NadekoBot/Common/SocketMessageEventWrapper.cs index 9d9ae4008..42b459134 100644 --- a/src/NadekoBot/Common/SocketMessageEventWrapper.cs +++ b/src/NadekoBot/Common/SocketMessageEventWrapper.cs @@ -1,8 +1,4 @@ -using Discord; -using Discord.WebSocket; -using System.Threading.Tasks; - -namespace NadekoBot.Common; +namespace NadekoBot.Common; public sealed class ReactionEventWrapper : IDisposable { diff --git a/src/NadekoBot/Common/TypeReaders/BotCommandTypeReader.cs b/src/NadekoBot/Common/TypeReaders/BotCommandTypeReader.cs index c81f46452..e469701b2 100644 --- a/src/NadekoBot/Common/TypeReaders/BotCommandTypeReader.cs +++ b/src/NadekoBot/Common/TypeReaders/BotCommandTypeReader.cs @@ -1,7 +1,4 @@ -using System.Threading.Tasks; -using Discord.Commands; -using NadekoBot.Services; -using NadekoBot.Modules.CustomReactions.Services; +using NadekoBot.Modules.CustomReactions.Services; namespace NadekoBot.Common.TypeReaders; diff --git a/src/NadekoBot/Common/TypeReaders/EmoteTypeReader.cs b/src/NadekoBot/Common/TypeReaders/EmoteTypeReader.cs index 19c357f06..a2198012c 100644 --- a/src/NadekoBot/Common/TypeReaders/EmoteTypeReader.cs +++ b/src/NadekoBot/Common/TypeReaders/EmoteTypeReader.cs @@ -1,8 +1,4 @@ -using System.Threading.Tasks; -using Discord; -using Discord.Commands; - -namespace NadekoBot.Common.TypeReaders; +namespace NadekoBot.Common.TypeReaders; public sealed class EmoteTypeReader : NadekoTypeReader { diff --git a/src/NadekoBot/Common/TypeReaders/GuildDateTimeTypeReader.cs b/src/NadekoBot/Common/TypeReaders/GuildDateTimeTypeReader.cs index 6abe79bbc..d7eed9908 100644 --- a/src/NadekoBot/Common/TypeReaders/GuildDateTimeTypeReader.cs +++ b/src/NadekoBot/Common/TypeReaders/GuildDateTimeTypeReader.cs @@ -1,6 +1,4 @@ -using System.Threading.Tasks; -using Discord.Commands; -using NadekoBot.Modules.Administration.Services; +using NadekoBot.Modules.Administration.Services; namespace NadekoBot.Common.TypeReaders; diff --git a/src/NadekoBot/Common/TypeReaders/GuildTypeReader.cs b/src/NadekoBot/Common/TypeReaders/GuildTypeReader.cs index b715a7eca..13e10247c 100644 --- a/src/NadekoBot/Common/TypeReaders/GuildTypeReader.cs +++ b/src/NadekoBot/Common/TypeReaders/GuildTypeReader.cs @@ -1,9 +1,4 @@ -using System.Threading.Tasks; -using Discord.Commands; -using Discord.WebSocket; -using Discord; - -namespace NadekoBot.Common.TypeReaders; +namespace NadekoBot.Common.TypeReaders; public sealed class GuildTypeReader : NadekoTypeReader { diff --git a/src/NadekoBot/Common/TypeReaders/KwumTypeReader.cs b/src/NadekoBot/Common/TypeReaders/KwumTypeReader.cs index 9c67700bd..689552668 100644 --- a/src/NadekoBot/Common/TypeReaders/KwumTypeReader.cs +++ b/src/NadekoBot/Common/TypeReaders/KwumTypeReader.cs @@ -1,7 +1,4 @@ -using System.Threading.Tasks; -using Discord.Commands; - -namespace NadekoBot.Common.TypeReaders; +namespace NadekoBot.Common.TypeReaders; public sealed class KwumTypeReader : NadekoTypeReader { diff --git a/src/NadekoBot/Common/TypeReaders/ModuleTypeReader.cs b/src/NadekoBot/Common/TypeReaders/ModuleTypeReader.cs index 9f868d239..b96bc07c6 100644 --- a/src/NadekoBot/Common/TypeReaders/ModuleTypeReader.cs +++ b/src/NadekoBot/Common/TypeReaders/ModuleTypeReader.cs @@ -1,6 +1,4 @@ -using System.Threading.Tasks; -using Discord.Commands; -using NadekoBot.Extensions; +using NadekoBot.Extensions; namespace NadekoBot.Common.TypeReaders; diff --git a/src/NadekoBot/Common/TypeReaders/NadekoTypeReader.cs b/src/NadekoBot/Common/TypeReaders/NadekoTypeReader.cs index 3cfeb6199..38889ad13 100644 --- a/src/NadekoBot/Common/TypeReaders/NadekoTypeReader.cs +++ b/src/NadekoBot/Common/TypeReaders/NadekoTypeReader.cs @@ -1,7 +1,4 @@ -using System.Threading.Tasks; -using Discord.Commands; - -namespace NadekoBot.Common.TypeReaders; +namespace NadekoBot.Common.TypeReaders; public abstract class NadekoTypeReader : TypeReader { diff --git a/src/NadekoBot/Common/TypeReaders/PermissionActionTypeReader.cs b/src/NadekoBot/Common/TypeReaders/PermissionActionTypeReader.cs index a3f068d31..158b6d964 100644 --- a/src/NadekoBot/Common/TypeReaders/PermissionActionTypeReader.cs +++ b/src/NadekoBot/Common/TypeReaders/PermissionActionTypeReader.cs @@ -1,6 +1,4 @@ -using System.Threading.Tasks; -using Discord.Commands; -using NadekoBot.Common.TypeReaders.Models; +using NadekoBot.Common.TypeReaders.Models; namespace NadekoBot.Common.TypeReaders; diff --git a/src/NadekoBot/Common/TypeReaders/Rgba32TypeReader.cs b/src/NadekoBot/Common/TypeReaders/Rgba32TypeReader.cs index 8bdd599dc..540ebdc7d 100644 --- a/src/NadekoBot/Common/TypeReaders/Rgba32TypeReader.cs +++ b/src/NadekoBot/Common/TypeReaders/Rgba32TypeReader.cs @@ -1,8 +1,5 @@ -using System.Threading.Tasks; -using Discord.Commands; -using SixLabors.ImageSharp; - -namespace NadekoBot.Common.TypeReaders; +namespace NadekoBot.Common.TypeReaders; +using Color = SixLabors.ImageSharp.Color; public sealed class Rgba32TypeReader : NadekoTypeReader { diff --git a/src/NadekoBot/Common/TypeReaders/ShmartNumberTypeReader.cs b/src/NadekoBot/Common/TypeReaders/ShmartNumberTypeReader.cs index a5103c091..f3e67728f 100644 --- a/src/NadekoBot/Common/TypeReaders/ShmartNumberTypeReader.cs +++ b/src/NadekoBot/Common/TypeReaders/ShmartNumberTypeReader.cs @@ -1,9 +1,6 @@ -using Discord.Commands; -using System.Text.RegularExpressions; -using System.Threading.Tasks; +using System.Text.RegularExpressions; using NadekoBot.Db; using NadekoBot.Modules.Gambling.Services; -using NadekoBot.Services; namespace NadekoBot.Common.TypeReaders; diff --git a/src/NadekoBot/Common/TypeReaders/StoopidTimeTypeReader.cs b/src/NadekoBot/Common/TypeReaders/StoopidTimeTypeReader.cs index c63111930..3c503a1e0 100644 --- a/src/NadekoBot/Common/TypeReaders/StoopidTimeTypeReader.cs +++ b/src/NadekoBot/Common/TypeReaders/StoopidTimeTypeReader.cs @@ -1,6 +1,4 @@ -using Discord.Commands; -using NadekoBot.Common.TypeReaders.Models; -using System.Threading.Tasks; +using NadekoBot.Common.TypeReaders.Models; namespace NadekoBot.Common.TypeReaders; diff --git a/src/NadekoBot/Db/Extensions/DiscordUserExtensions.cs b/src/NadekoBot/Db/Extensions/DiscordUserExtensions.cs index 22e6e593e..3db4ffadf 100644 --- a/src/NadekoBot/Db/Extensions/DiscordUserExtensions.cs +++ b/src/NadekoBot/Db/Extensions/DiscordUserExtensions.cs @@ -1,6 +1,5 @@ using NadekoBot.Db.Models; using Microsoft.EntityFrameworkCore; -using Discord; using LinqToDB; using LinqToDB.EntityFrameworkCore; using NadekoBot.Services.Database; diff --git a/src/NadekoBot/Db/Extensions/MusicPlayerSettingsExtensions.cs b/src/NadekoBot/Db/Extensions/MusicPlayerSettingsExtensions.cs index d111f53d0..e9d77600f 100644 --- a/src/NadekoBot/Db/Extensions/MusicPlayerSettingsExtensions.cs +++ b/src/NadekoBot/Db/Extensions/MusicPlayerSettingsExtensions.cs @@ -1,5 +1,4 @@ -using System.Threading.Tasks; -using Microsoft.EntityFrameworkCore; +using Microsoft.EntityFrameworkCore; using NadekoBot.Services.Database.Models; namespace NadekoBot.Db; diff --git a/src/NadekoBot/Db/Extensions/QuoteExtensions.cs b/src/NadekoBot/Db/Extensions/QuoteExtensions.cs index 03e006fc6..91be224e7 100644 --- a/src/NadekoBot/Db/Extensions/QuoteExtensions.cs +++ b/src/NadekoBot/Db/Extensions/QuoteExtensions.cs @@ -1,7 +1,5 @@ using NadekoBot.Services.Database.Models; -using System.Threading.Tasks; using Microsoft.EntityFrameworkCore; -using NadekoBot.Common; namespace NadekoBot.Db; diff --git a/src/NadekoBot/Db/Extensions/WarningExtensions.cs b/src/NadekoBot/Db/Extensions/WarningExtensions.cs index f66369a92..c2a1ebdb7 100644 --- a/src/NadekoBot/Db/Extensions/WarningExtensions.cs +++ b/src/NadekoBot/Db/Extensions/WarningExtensions.cs @@ -1,6 +1,5 @@ using NadekoBot.Services.Database.Models; using Microsoft.EntityFrameworkCore; -using System.Threading.Tasks; namespace NadekoBot.Db; diff --git a/src/NadekoBot/Db/Models/DiscordPemOverride.cs b/src/NadekoBot/Db/Models/DiscordPemOverride.cs index 55d102742..a7fbf10bd 100644 --- a/src/NadekoBot/Db/Models/DiscordPemOverride.cs +++ b/src/NadekoBot/Db/Models/DiscordPemOverride.cs @@ -1,6 +1,4 @@ -using Discord; - -namespace NadekoBot.Services.Database.Models; +namespace NadekoBot.Services.Database.Models; public class DiscordPermOverride : DbEntity { diff --git a/src/NadekoBot/Db/Models/FilterChannelId.cs b/src/NadekoBot/Db/Models/FilterChannelId.cs index 7a9468f91..58907525c 100644 --- a/src/NadekoBot/Db/Models/FilterChannelId.cs +++ b/src/NadekoBot/Db/Models/FilterChannelId.cs @@ -4,15 +4,26 @@ public class FilterChannelId : DbEntity { public ulong ChannelId { get; set; } - public override bool Equals(object obj) - { - return obj is FilterChannelId f - ? f.ChannelId == ChannelId - : false; - } + public bool Equals(FilterChannelId other) + => ChannelId == other.ChannelId; - public override int GetHashCode() - { - return ChannelId.GetHashCode(); - } + public override bool Equals(object obj) + => obj is FilterChannelId fci && Equals(fci); + + public override int GetHashCode() + => ChannelId.GetHashCode(); +} + +public class FilterInvitesChannelId : DbEntity +{ + public ulong ChannelId { get; set; } + + public bool Equals(FilterInvitesChannelId other) + => ChannelId == other.ChannelId; + + public override bool Equals(object obj) + => obj is FilterInvitesChannelId fci && Equals(fci); + + public override int GetHashCode() + => ChannelId.GetHashCode(); } \ No newline at end of file diff --git a/src/NadekoBot/Db/Models/FilterLinksChannelId.cs b/src/NadekoBot/Db/Models/FilterLinksChannelId.cs index afbcf7bec..469baf233 100644 --- a/src/NadekoBot/Db/Models/FilterLinksChannelId.cs +++ b/src/NadekoBot/Db/Models/FilterLinksChannelId.cs @@ -5,14 +5,9 @@ public class FilterLinksChannelId : DbEntity public ulong ChannelId { get; set; } public override bool Equals(object obj) - { - return obj is FilterLinksChannelId f - ? f.ChannelId == ChannelId - : false; - } + => obj is FilterLinksChannelId f + && f.ChannelId == ChannelId; - public override int GetHashCode() - { - return ChannelId.GetHashCode(); - } + public override int GetHashCode() + => ChannelId.GetHashCode(); } \ No newline at end of file diff --git a/src/NadekoBot/Db/Models/RotatingPlayingStatus.cs b/src/NadekoBot/Db/Models/RotatingPlayingStatus.cs index 460e0bc76..bffeddffe 100644 --- a/src/NadekoBot/Db/Models/RotatingPlayingStatus.cs +++ b/src/NadekoBot/Db/Models/RotatingPlayingStatus.cs @@ -1,6 +1,4 @@ -using Discord; - -namespace NadekoBot.Services.Database.Models; +namespace NadekoBot.Services.Database.Models; public class RotatingPlayingStatus : DbEntity { diff --git a/src/NadekoBot/Db/NadekoContext.cs b/src/NadekoBot/Db/NadekoContext.cs index bf486c04a..b5a63a01c 100644 --- a/src/NadekoBot/Db/NadekoContext.cs +++ b/src/NadekoBot/Db/NadekoContext.cs @@ -2,7 +2,6 @@ using Microsoft.EntityFrameworkCore; using Microsoft.EntityFrameworkCore.Design; using NadekoBot.Services.Database.Models; -using System.IO; using Microsoft.Extensions.Logging; using NadekoBot.Db.Models; diff --git a/src/NadekoBot/GlobalUsings.cs b/src/NadekoBot/GlobalUsings.cs new file mode 100644 index 000000000..22da4727e --- /dev/null +++ b/src/NadekoBot/GlobalUsings.cs @@ -0,0 +1,13 @@ +global using Serilog; + +global using NadekoBot; +global using NadekoBot.Services; +global using NadekoBot.Common; +global using NadekoBot.Common.Attributes; + +global using Discord; +global using Discord.Commands; +global using Discord.Net; +global using Discord.WebSocket; + +global using System.Collections.Concurrent; \ No newline at end of file diff --git a/src/NadekoBot/Modules/Administration/Administration.cs b/src/NadekoBot/Modules/Administration/Administration.cs index 72acf0988..c5d7d234e 100644 --- a/src/NadekoBot/Modules/Administration/Administration.cs +++ b/src/NadekoBot/Modules/Administration/Administration.cs @@ -1,11 +1,6 @@ -using Discord; -using Discord.Commands; -using Discord.WebSocket; -using NadekoBot.Common.Attributes; using NadekoBot.Common.TypeReaders.Models; using NadekoBot.Extensions; using NadekoBot.Modules.Administration.Services; -using System.Threading.Tasks; namespace NadekoBot.Modules.Administration; diff --git a/src/NadekoBot/Modules/Administration/AutoAssignRoleCommands.cs b/src/NadekoBot/Modules/Administration/AutoAssignRoleCommands.cs index 4652aa315..61d88df68 100644 --- a/src/NadekoBot/Modules/Administration/AutoAssignRoleCommands.cs +++ b/src/NadekoBot/Modules/Administration/AutoAssignRoleCommands.cs @@ -1,8 +1,4 @@ -using Discord; -using Discord.Commands; -using NadekoBot.Extensions; -using System.Threading.Tasks; -using NadekoBot.Common.Attributes; +using NadekoBot.Extensions; using NadekoBot.Modules.Administration.Services; namespace NadekoBot.Modules.Administration; diff --git a/src/NadekoBot/Modules/Administration/Common/ProtectionStats.cs b/src/NadekoBot/Modules/Administration/Common/ProtectionStats.cs index 16bf9dae8..0c84585dc 100644 --- a/src/NadekoBot/Modules/Administration/Common/ProtectionStats.cs +++ b/src/NadekoBot/Modules/Administration/Common/ProtectionStats.cs @@ -1,7 +1,4 @@ -using System.Collections.Concurrent; -using System.Threading; -using Discord; -using NadekoBot.Common.Collections; +using NadekoBot.Common.Collections; using NadekoBot.Services.Database.Models; namespace NadekoBot.Modules.Administration.Common; diff --git a/src/NadekoBot/Modules/Administration/Common/PunishQueueItem.cs b/src/NadekoBot/Modules/Administration/Common/PunishQueueItem.cs index 370b202c4..0b1d0fcae 100644 --- a/src/NadekoBot/Modules/Administration/Common/PunishQueueItem.cs +++ b/src/NadekoBot/Modules/Administration/Common/PunishQueueItem.cs @@ -1,5 +1,4 @@ -using Discord; -using NadekoBot.Services.Database.Models; +using NadekoBot.Services.Database.Models; namespace NadekoBot.Modules.Administration.Common; diff --git a/src/NadekoBot/Modules/Administration/Common/UserSpamStats.cs b/src/NadekoBot/Modules/Administration/Common/UserSpamStats.cs index c28158750..c0a881390 100644 --- a/src/NadekoBot/Modules/Administration/Common/UserSpamStats.cs +++ b/src/NadekoBot/Modules/Administration/Common/UserSpamStats.cs @@ -1,8 +1,4 @@ -using System.Collections.Concurrent; -using System.Threading; -using Discord; - -namespace NadekoBot.Modules.Administration.Common; +namespace NadekoBot.Modules.Administration.Common; public sealed class UserSpamStats : IDisposable { diff --git a/src/NadekoBot/Modules/Administration/DangerousCommands.cs b/src/NadekoBot/Modules/Administration/DangerousCommands.cs index afaf50acc..f2b4d6534 100644 --- a/src/NadekoBot/Modules/Administration/DangerousCommands.cs +++ b/src/NadekoBot/Modules/Administration/DangerousCommands.cs @@ -1,8 +1,4 @@ -using Discord.Commands; -using NadekoBot.Common.Attributes; -using NadekoBot.Extensions; -using System.Threading.Tasks; -using Discord; +using NadekoBot.Extensions; using NadekoBot.Modules.Administration.Services; #if !GLOBAL_NADEKO diff --git a/src/NadekoBot/Modules/Administration/DiscordPermOverrideCommands.cs b/src/NadekoBot/Modules/Administration/DiscordPermOverrideCommands.cs index 42c444356..a672e2533 100644 --- a/src/NadekoBot/Modules/Administration/DiscordPermOverrideCommands.cs +++ b/src/NadekoBot/Modules/Administration/DiscordPermOverrideCommands.cs @@ -1,8 +1,4 @@ -using System.Threading.Tasks; -using Discord; -using Discord.Commands; -using NadekoBot.Common.Attributes; -using NadekoBot.Common.TypeReaders; +using NadekoBot.Common.TypeReaders; using NadekoBot.Extensions; using NadekoBot.Modules.Administration.Services; diff --git a/src/NadekoBot/Modules/Administration/GameChannelCommands.cs b/src/NadekoBot/Modules/Administration/GameChannelCommands.cs index fbe28def3..2d016975c 100644 --- a/src/NadekoBot/Modules/Administration/GameChannelCommands.cs +++ b/src/NadekoBot/Modules/Administration/GameChannelCommands.cs @@ -1,8 +1,4 @@ -using Discord; -using Discord.Commands; -using System.Threading.Tasks; -using NadekoBot.Common.Attributes; -using NadekoBot.Modules.Administration.Services; +using NadekoBot.Modules.Administration.Services; namespace NadekoBot.Modules.Administration; diff --git a/src/NadekoBot/Modules/Administration/LocalizationCommands.cs b/src/NadekoBot/Modules/Administration/LocalizationCommands.cs index 6e36df041..a16242a59 100644 --- a/src/NadekoBot/Modules/Administration/LocalizationCommands.cs +++ b/src/NadekoBot/Modules/Administration/LocalizationCommands.cs @@ -1,9 +1,5 @@ -using Discord; -using Discord.Commands; -using NadekoBot.Extensions; +using NadekoBot.Extensions; using System.Globalization; -using System.Threading.Tasks; -using NadekoBot.Common.Attributes; namespace NadekoBot.Modules.Administration; diff --git a/src/NadekoBot/Modules/Administration/LogCommands.cs b/src/NadekoBot/Modules/Administration/LogCommands.cs index cc949b226..b8f498469 100644 --- a/src/NadekoBot/Modules/Administration/LogCommands.cs +++ b/src/NadekoBot/Modules/Administration/LogCommands.cs @@ -1,12 +1,7 @@ -using Discord; -using Discord.Commands; -using NadekoBot.Common; -using NadekoBot.Common.Attributes; -using NadekoBot.Common.TypeReaders.Models; +using NadekoBot.Common.TypeReaders.Models; using NadekoBot.Services.Database.Models; using NadekoBot.Extensions; using NadekoBot.Modules.Administration.Services; -using System.Threading.Tasks; namespace NadekoBot.Modules.Administration; diff --git a/src/NadekoBot/Modules/Administration/MuteCommands.cs b/src/NadekoBot/Modules/Administration/MuteCommands.cs index e876520b4..9fe27e052 100644 --- a/src/NadekoBot/Modules/Administration/MuteCommands.cs +++ b/src/NadekoBot/Modules/Administration/MuteCommands.cs @@ -1,10 +1,5 @@ -using Discord; -using Discord.Commands; -using NadekoBot.Common.Attributes; -using NadekoBot.Common.TypeReaders.Models; +using NadekoBot.Common.TypeReaders.Models; using NadekoBot.Modules.Administration.Services; -using System.Threading.Tasks; -using Discord.WebSocket; using NadekoBot.Extensions; namespace NadekoBot.Modules.Administration; diff --git a/src/NadekoBot/Modules/Administration/PlayingRotateCommands.cs b/src/NadekoBot/Modules/Administration/PlayingRotateCommands.cs index 799498896..d32f9d606 100644 --- a/src/NadekoBot/Modules/Administration/PlayingRotateCommands.cs +++ b/src/NadekoBot/Modules/Administration/PlayingRotateCommands.cs @@ -1,8 +1,4 @@ -using Discord.Commands; -using System.Threading.Tasks; -using NadekoBot.Common.Attributes; -using NadekoBot.Modules.Administration.Services; -using Discord; +using NadekoBot.Modules.Administration.Services; namespace NadekoBot.Modules.Administration; diff --git a/src/NadekoBot/Modules/Administration/PrefixCommands.cs b/src/NadekoBot/Modules/Administration/PrefixCommands.cs index 2509e17eb..72def941b 100644 --- a/src/NadekoBot/Modules/Administration/PrefixCommands.cs +++ b/src/NadekoBot/Modules/Administration/PrefixCommands.cs @@ -1,9 +1,4 @@ -using Discord; -using Discord.Commands; -using System.Threading.Tasks; -using NadekoBot.Common.Attributes; - -namespace NadekoBot.Modules.Administration; +namespace NadekoBot.Modules.Administration; public partial class Administration { diff --git a/src/NadekoBot/Modules/Administration/ProtectionCommands.cs b/src/NadekoBot/Modules/Administration/ProtectionCommands.cs index 6737bb1e9..c498f7e5a 100644 --- a/src/NadekoBot/Modules/Administration/ProtectionCommands.cs +++ b/src/NadekoBot/Modules/Administration/ProtectionCommands.cs @@ -1,11 +1,7 @@ -using Discord; -using Discord.Commands; -using NadekoBot.Common.Attributes; -using NadekoBot.Services.Database.Models; +using NadekoBot.Services.Database.Models; using NadekoBot.Extensions; using NadekoBot.Modules.Administration.Common; using NadekoBot.Modules.Administration.Services; -using System.Threading.Tasks; using NadekoBot.Common.TypeReaders.Models; namespace NadekoBot.Modules.Administration; diff --git a/src/NadekoBot/Modules/Administration/PruneCommands.cs b/src/NadekoBot/Modules/Administration/PruneCommands.cs index dc019a1c9..fe6d2b5c1 100644 --- a/src/NadekoBot/Modules/Administration/PruneCommands.cs +++ b/src/NadekoBot/Modules/Administration/PruneCommands.cs @@ -1,8 +1,4 @@ -using Discord; -using Discord.Commands; -using NadekoBot.Extensions; -using System.Threading.Tasks; -using NadekoBot.Common.Attributes; +using NadekoBot.Extensions; using NadekoBot.Modules.Administration.Services; using ITextChannel = Discord.ITextChannel; diff --git a/src/NadekoBot/Modules/Administration/RoleCommands.cs b/src/NadekoBot/Modules/Administration/RoleCommands.cs index 8e824d811..3632e1441 100644 --- a/src/NadekoBot/Modules/Administration/RoleCommands.cs +++ b/src/NadekoBot/Modules/Administration/RoleCommands.cs @@ -1,14 +1,8 @@ -using Discord; -using Discord.Commands; -using Discord.WebSocket; -using NadekoBot.Common; -using NadekoBot.Common.Attributes; -using NadekoBot.Services.Database.Models; +using NadekoBot.Services.Database.Models; using NadekoBot.Extensions; using NadekoBot.Modules.Administration.Services; using SixLabors.ImageSharp.PixelFormats; using System.Net; -using System.Threading.Tasks; namespace NadekoBot.Modules.Administration; diff --git a/src/NadekoBot/Modules/Administration/SelfAssignedRolesCommands.cs b/src/NadekoBot/Modules/Administration/SelfAssignedRolesCommands.cs index 5e9f6afb7..4fa73058b 100644 --- a/src/NadekoBot/Modules/Administration/SelfAssignedRolesCommands.cs +++ b/src/NadekoBot/Modules/Administration/SelfAssignedRolesCommands.cs @@ -1,8 +1,4 @@ using System.Text; -using System.Threading.Tasks; -using Discord; -using Discord.Commands; -using NadekoBot.Common.Attributes; using NadekoBot.Modules.Administration.Services; using NadekoBot.Extensions; diff --git a/src/NadekoBot/Modules/Administration/SelfCommands.cs b/src/NadekoBot/Modules/Administration/SelfCommands.cs index e6bb53282..1e7b04910 100644 --- a/src/NadekoBot/Modules/Administration/SelfCommands.cs +++ b/src/NadekoBot/Modules/Administration/SelfCommands.cs @@ -1,14 +1,6 @@ -using Discord; -using Discord.Commands; -using Discord.Net; -using Discord.WebSocket; -using NadekoBot.Common.Attributes; -using NadekoBot.Common.Replacements; using NadekoBot.Services.Database.Models; using NadekoBot.Extensions; using NadekoBot.Modules.Administration.Services; -using System.Threading.Tasks; -using NadekoBot.Services; namespace NadekoBot.Modules.Administration; diff --git a/src/NadekoBot/Modules/Administration/ServerGreetCommands.cs b/src/NadekoBot/Modules/Administration/ServerGreetCommands.cs index bf3eb7484..0b7eeb826 100644 --- a/src/NadekoBot/Modules/Administration/ServerGreetCommands.cs +++ b/src/NadekoBot/Modules/Administration/ServerGreetCommands.cs @@ -1,9 +1,4 @@ -using Discord; -using Discord.Commands; -using NadekoBot.Extensions; -using NadekoBot.Services; -using System.Threading.Tasks; -using NadekoBot.Common.Attributes; +using NadekoBot.Extensions; namespace NadekoBot.Modules.Administration; diff --git a/src/NadekoBot/Modules/Administration/Services/AdministrationService.cs b/src/NadekoBot/Modules/Administration/Services/AdministrationService.cs index 66ca169aa..53128663e 100644 --- a/src/NadekoBot/Modules/Administration/Services/AdministrationService.cs +++ b/src/NadekoBot/Modules/Administration/Services/AdministrationService.cs @@ -1,14 +1,7 @@ -using Discord; -using Discord.Commands; -using Discord.WebSocket; -using Microsoft.EntityFrameworkCore; +using Microsoft.EntityFrameworkCore; using NadekoBot.Common.Collections; -using NadekoBot.Common.Replacements; -using NadekoBot.Services; using NadekoBot.Services.Database.Models; using NadekoBot.Extensions; -using System.Collections.Concurrent; -using System.Threading.Tasks; using NadekoBot.Db; namespace NadekoBot.Modules.Administration.Services; diff --git a/src/NadekoBot/Modules/Administration/Services/AutoAssignRoleService.cs b/src/NadekoBot/Modules/Administration/Services/AutoAssignRoleService.cs index dc11313a2..82ee340fd 100644 --- a/src/NadekoBot/Modules/Administration/Services/AutoAssignRoleService.cs +++ b/src/NadekoBot/Modules/Administration/Services/AutoAssignRoleService.cs @@ -1,8 +1,4 @@ -using System.Collections.Concurrent; -using System.Threading.Tasks; -using Discord.WebSocket; -using NadekoBot.Services; -using System.Threading.Channels; +using System.Threading.Channels; using LinqToDB; using Microsoft.EntityFrameworkCore; using NadekoBot.Services.Database.Models; diff --git a/src/NadekoBot/Modules/Administration/Services/DangerousCommandsService.cs b/src/NadekoBot/Modules/Administration/Services/DangerousCommandsService.cs index 54c4f1900..2b591ce74 100644 --- a/src/NadekoBot/Modules/Administration/Services/DangerousCommandsService.cs +++ b/src/NadekoBot/Modules/Administration/Services/DangerousCommandsService.cs @@ -1,6 +1,4 @@ -using System.Threading.Tasks; using Microsoft.EntityFrameworkCore; -using NadekoBot.Services; using LinqToDB; using LinqToDB.EntityFrameworkCore; using NadekoBot.Services.Database.Models; diff --git a/src/NadekoBot/Modules/Administration/Services/DiscordPermOverrideService.cs b/src/NadekoBot/Modules/Administration/Services/DiscordPermOverrideService.cs index 2584c837d..e3ba6dc44 100644 --- a/src/NadekoBot/Modules/Administration/Services/DiscordPermOverrideService.cs +++ b/src/NadekoBot/Modules/Administration/Services/DiscordPermOverrideService.cs @@ -1,10 +1,5 @@ -using System.Collections.Concurrent; -using System.Threading.Tasks; -using Discord; -using Discord.Commands; -using Microsoft.EntityFrameworkCore; +using Microsoft.EntityFrameworkCore; using NadekoBot.Common.ModuleBehaviors; -using NadekoBot.Services; using NadekoBot.Services.Database.Models; using NadekoBot.Extensions; diff --git a/src/NadekoBot/Modules/Administration/Services/GameVoiceChannelService.cs b/src/NadekoBot/Modules/Administration/Services/GameVoiceChannelService.cs index eb80f889a..1bfc4905d 100644 --- a/src/NadekoBot/Modules/Administration/Services/GameVoiceChannelService.cs +++ b/src/NadekoBot/Modules/Administration/Services/GameVoiceChannelService.cs @@ -1,8 +1,5 @@ -using System.Threading.Tasks; -using Discord.WebSocket; -using NadekoBot.Common.Collections; +using NadekoBot.Common.Collections; using NadekoBot.Extensions; -using NadekoBot.Services; using NadekoBot.Db; namespace NadekoBot.Modules.Administration.Services; diff --git a/src/NadekoBot/Modules/Administration/Services/GuildTimezoneService.cs b/src/NadekoBot/Modules/Administration/Services/GuildTimezoneService.cs index 86f927642..c04a6d625 100644 --- a/src/NadekoBot/Modules/Administration/Services/GuildTimezoneService.cs +++ b/src/NadekoBot/Modules/Administration/Services/GuildTimezoneService.cs @@ -1,9 +1,5 @@ -using System.Collections.Concurrent; -using Discord.WebSocket; -using NadekoBot.Extensions; -using NadekoBot.Services; +using NadekoBot.Extensions; using NadekoBot.Services.Database.Models; -using System.Threading.Tasks; using NadekoBot.Db; namespace NadekoBot.Modules.Administration.Services; diff --git a/src/NadekoBot/Modules/Administration/Services/ImageOnlyChannelService.cs b/src/NadekoBot/Modules/Administration/Services/ImageOnlyChannelService.cs index 6ca998c06..f1f759358 100644 --- a/src/NadekoBot/Modules/Administration/Services/ImageOnlyChannelService.cs +++ b/src/NadekoBot/Modules/Administration/Services/ImageOnlyChannelService.cs @@ -1,16 +1,10 @@ -using System.Collections.Concurrent; -using System.Net; +using System.Net; using System.Threading.Channels; -using System.Threading.Tasks; -using Discord; -using Discord.Net; -using Discord.WebSocket; using LinqToDB; using Microsoft.Extensions.Caching.Memory; using NadekoBot.Common.Collections; using NadekoBot.Common.ModuleBehaviors; using NadekoBot.Extensions; -using NadekoBot.Services; namespace NadekoBot.Modules.Administration.Services; diff --git a/src/NadekoBot/Modules/Administration/Services/LogCommandService.cs b/src/NadekoBot/Modules/Administration/Services/LogCommandService.cs index 5613a6ace..ad7212d6a 100644 --- a/src/NadekoBot/Modules/Administration/Services/LogCommandService.cs +++ b/src/NadekoBot/Modules/Administration/Services/LogCommandService.cs @@ -1,12 +1,6 @@ -using System.Collections.Concurrent; -using System.Threading; -using System.Threading.Tasks; -using Discord; -using Discord.WebSocket; -using Microsoft.EntityFrameworkCore; +using Microsoft.EntityFrameworkCore; using Microsoft.Extensions.Caching.Memory; using NadekoBot.Common.Collections; -using NadekoBot.Services; using NadekoBot.Services.Database.Models; using NadekoBot.Db; using NadekoBot.Extensions; diff --git a/src/NadekoBot/Modules/Administration/Services/MuteService.cs b/src/NadekoBot/Modules/Administration/Services/MuteService.cs index 9b5c04244..b9840e6d1 100644 --- a/src/NadekoBot/Modules/Administration/Services/MuteService.cs +++ b/src/NadekoBot/Modules/Administration/Services/MuteService.cs @@ -1,12 +1,6 @@ -using System.Collections.Concurrent; -using System.Threading; -using System.Threading.Tasks; -using Discord; -using Discord.WebSocket; -using Microsoft.EntityFrameworkCore; +using Microsoft.EntityFrameworkCore; using NadekoBot.Common.Collections; using NadekoBot.Extensions; -using NadekoBot.Services; using NadekoBot.Services.Database.Models; using NadekoBot.Db; diff --git a/src/NadekoBot/Modules/Administration/Services/PlayingRotateService.cs b/src/NadekoBot/Modules/Administration/Services/PlayingRotateService.cs index 65946c733..3227b1866 100644 --- a/src/NadekoBot/Modules/Administration/Services/PlayingRotateService.cs +++ b/src/NadekoBot/Modules/Administration/Services/PlayingRotateService.cs @@ -1,12 +1,5 @@ -using System.Threading; -using Discord.WebSocket; -using NadekoBot.Common.Replacements; -using NadekoBot.Services; -using NadekoBot.Services.Database.Models; -using Discord; -using System.Threading.Tasks; +using NadekoBot.Services.Database.Models; using Microsoft.EntityFrameworkCore; -using NadekoBot.Common; namespace NadekoBot.Modules.Administration.Services; diff --git a/src/NadekoBot/Modules/Administration/Services/ProtectionService.cs b/src/NadekoBot/Modules/Administration/Services/ProtectionService.cs index 3c3aa8262..13c8f22b1 100644 --- a/src/NadekoBot/Modules/Administration/Services/ProtectionService.cs +++ b/src/NadekoBot/Modules/Administration/Services/ProtectionService.cs @@ -1,10 +1,5 @@ -using System.Collections.Concurrent; -using System.Threading.Channels; -using System.Threading.Tasks; -using Discord; -using Discord.WebSocket; +using System.Threading.Channels; using NadekoBot.Modules.Administration.Common; -using NadekoBot.Services; using NadekoBot.Services.Database.Models; using NadekoBot.Extensions; using Microsoft.EntityFrameworkCore; diff --git a/src/NadekoBot/Modules/Administration/Services/PruneService.cs b/src/NadekoBot/Modules/Administration/Services/PruneService.cs index 4adcd9087..6bba46235 100644 --- a/src/NadekoBot/Modules/Administration/Services/PruneService.cs +++ b/src/NadekoBot/Modules/Administration/Services/PruneService.cs @@ -1,8 +1,5 @@ -using System.Threading.Tasks; -using Discord; -using NadekoBot.Common.Collections; +using NadekoBot.Common.Collections; using NadekoBot.Extensions; -using NadekoBot.Services; namespace NadekoBot.Modules.Administration.Services; diff --git a/src/NadekoBot/Modules/Administration/Services/RoleCommandsService.cs b/src/NadekoBot/Modules/Administration/Services/RoleCommandsService.cs index fd6f2faa0..a152dc2f7 100644 --- a/src/NadekoBot/Modules/Administration/Services/RoleCommandsService.cs +++ b/src/NadekoBot/Modules/Administration/Services/RoleCommandsService.cs @@ -1,16 +1,10 @@ -using Discord; -using Discord.WebSocket; -using Microsoft.EntityFrameworkCore; +using Microsoft.EntityFrameworkCore; using NadekoBot.Common.Collections; -using NadekoBot.Services; using NadekoBot.Services.Database.Models; using NadekoBot.Extensions; -using System.Collections.Concurrent; -using System.Threading.Tasks; using LinqToDB; using LinqToDB.EntityFrameworkCore; using NadekoBot.Db; -using System.Threading; namespace NadekoBot.Modules.Administration.Services; diff --git a/src/NadekoBot/Modules/Administration/Services/SelfAssignedRolesService.cs b/src/NadekoBot/Modules/Administration/Services/SelfAssignedRolesService.cs index 0cae7b0ec..21191d7a9 100644 --- a/src/NadekoBot/Modules/Administration/Services/SelfAssignedRolesService.cs +++ b/src/NadekoBot/Modules/Administration/Services/SelfAssignedRolesService.cs @@ -1,7 +1,4 @@ -using Discord; -using NadekoBot.Services; -using NadekoBot.Services.Database.Models; -using System.Threading.Tasks; +using NadekoBot.Services.Database.Models; using Microsoft.EntityFrameworkCore; using NadekoBot.Db; using NadekoBot.Modules.Xp; diff --git a/src/NadekoBot/Modules/Administration/Services/SelfService.cs b/src/NadekoBot/Modules/Administration/Services/SelfService.cs index bdf91015d..f4c569204 100644 --- a/src/NadekoBot/Modules/Administration/Services/SelfService.cs +++ b/src/NadekoBot/Modules/Administration/Services/SelfService.cs @@ -1,16 +1,8 @@ using System.Collections.Immutable; -using System.Threading.Tasks; -using Discord; -using Discord.WebSocket; using NadekoBot.Common.ModuleBehaviors; using NadekoBot.Extensions; -using NadekoBot.Services; using Microsoft.EntityFrameworkCore; using NadekoBot.Services.Database.Models; -using System.Threading; -using System.Collections.Concurrent; -using System.Net.Http; -using NadekoBot.Common; namespace NadekoBot.Modules.Administration.Services; diff --git a/src/NadekoBot/Modules/Administration/Services/UserPunishService.cs b/src/NadekoBot/Modules/Administration/Services/UserPunishService.cs index 844842183..011978e24 100644 --- a/src/NadekoBot/Modules/Administration/Services/UserPunishService.cs +++ b/src/NadekoBot/Modules/Administration/Services/UserPunishService.cs @@ -1,12 +1,5 @@ -using System.Threading; -using System.Threading.Tasks; -using Discord; -using Discord.Commands; -using Discord.WebSocket; using Microsoft.EntityFrameworkCore; -using NadekoBot.Common.Replacements; using NadekoBot.Common.TypeReaders.Models; -using NadekoBot.Services; using NadekoBot.Services.Database.Models; using NadekoBot.Db; using NadekoBot.Extensions; diff --git a/src/NadekoBot/Modules/Administration/Services/VcRoleService.cs b/src/NadekoBot/Modules/Administration/Services/VcRoleService.cs index f1a181877..50a5de77d 100644 --- a/src/NadekoBot/Modules/Administration/Services/VcRoleService.cs +++ b/src/NadekoBot/Modules/Administration/Services/VcRoleService.cs @@ -1,9 +1,4 @@ -using System.Collections.Concurrent; -using System.Threading.Tasks; -using Discord; -using Discord.WebSocket; -using Microsoft.EntityFrameworkCore; -using NadekoBot.Services; +using Microsoft.EntityFrameworkCore; using NadekoBot.Services.Database.Models; using NadekoBot.Db; diff --git a/src/NadekoBot/Modules/Administration/TimeZoneCommands.cs b/src/NadekoBot/Modules/Administration/TimeZoneCommands.cs index 3245b5b0d..13a30811a 100644 --- a/src/NadekoBot/Modules/Administration/TimeZoneCommands.cs +++ b/src/NadekoBot/Modules/Administration/TimeZoneCommands.cs @@ -1,8 +1,4 @@ -using Discord; -using Discord.Commands; -using NadekoBot.Extensions; -using System.Threading.Tasks; -using NadekoBot.Common.Attributes; +using NadekoBot.Extensions; using NadekoBot.Modules.Administration.Services; namespace NadekoBot.Modules.Administration; diff --git a/src/NadekoBot/Modules/Administration/UserPunishCommands.cs b/src/NadekoBot/Modules/Administration/UserPunishCommands.cs index 2c67ff407..77b5bb4a6 100644 --- a/src/NadekoBot/Modules/Administration/UserPunishCommands.cs +++ b/src/NadekoBot/Modules/Administration/UserPunishCommands.cs @@ -1,14 +1,8 @@ using CommandLine; -using Discord; -using Discord.Commands; -using Discord.WebSocket; -using NadekoBot.Common.Attributes; -using NadekoBot.Common; using NadekoBot.Common.TypeReaders.Models; using NadekoBot.Services.Database.Models; using NadekoBot.Extensions; using NadekoBot.Modules.Administration.Services; -using System.Threading.Tasks; using NadekoBot.Modules.Permissions.Services; namespace NadekoBot.Modules.Administration; diff --git a/src/NadekoBot/Modules/Administration/VcRoleCommands.cs b/src/NadekoBot/Modules/Administration/VcRoleCommands.cs index f4fb76296..aa09267fc 100644 --- a/src/NadekoBot/Modules/Administration/VcRoleCommands.cs +++ b/src/NadekoBot/Modules/Administration/VcRoleCommands.cs @@ -1,10 +1,4 @@ -using System.Collections.Concurrent; -using Discord; -using Discord.Commands; -using System.Threading.Tasks; -using Discord.WebSocket; -using NadekoBot.Common.Attributes; -using NadekoBot.Extensions; +using NadekoBot.Extensions; using NadekoBot.Modules.Administration.Services; namespace NadekoBot.Modules.Administration; diff --git a/src/NadekoBot/Modules/CustomReactions/Common/ExportedExpr.cs b/src/NadekoBot/Modules/CustomReactions/Common/ExportedExpr.cs index b1a1310dc..8b579a0d1 100644 --- a/src/NadekoBot/Modules/CustomReactions/Common/ExportedExpr.cs +++ b/src/NadekoBot/Modules/CustomReactions/Common/ExportedExpr.cs @@ -1,5 +1,4 @@ using NadekoBot.Services.Database.Models; -using NadekoBot.Common; namespace NadekoBot.Modules.CustomReactions; diff --git a/src/NadekoBot/Modules/CustomReactions/CustomReactions.cs b/src/NadekoBot/Modules/CustomReactions/CustomReactions.cs index 0412dadac..7ad27c17f 100644 --- a/src/NadekoBot/Modules/CustomReactions/CustomReactions.cs +++ b/src/NadekoBot/Modules/CustomReactions/CustomReactions.cs @@ -1,11 +1,5 @@ -using Discord; -using Discord.Commands; -using NadekoBot.Common.Attributes; -using NadekoBot.Extensions; +using NadekoBot.Extensions; using NadekoBot.Modules.CustomReactions.Services; -using System.Net.Http; -using System.Threading.Tasks; -using NadekoBot.Common; namespace NadekoBot.Modules.CustomReactions; diff --git a/src/NadekoBot/Modules/CustomReactions/Extensions/CustomReactionExtensions.cs b/src/NadekoBot/Modules/CustomReactions/Extensions/CustomReactionExtensions.cs index 042f01851..aa95b28ae 100644 --- a/src/NadekoBot/Modules/CustomReactions/Extensions/CustomReactionExtensions.cs +++ b/src/NadekoBot/Modules/CustomReactions/Extensions/CustomReactionExtensions.cs @@ -1,10 +1,6 @@ -using Discord; -using Discord.WebSocket; -using NadekoBot.Common.Replacements; -using NadekoBot.Services.Database.Models; +using NadekoBot.Services.Database.Models; using NadekoBot.Extensions; using System.Runtime.CompilerServices; -using System.Threading.Tasks; namespace NadekoBot.Modules.CustomReactions.Extensions; diff --git a/src/NadekoBot/Modules/CustomReactions/Services/CustomReactionsService.cs b/src/NadekoBot/Modules/CustomReactions/Services/CustomReactionsService.cs index 601e39b83..64c5eecc9 100644 --- a/src/NadekoBot/Modules/CustomReactions/Services/CustomReactionsService.cs +++ b/src/NadekoBot/Modules/CustomReactions/Services/CustomReactionsService.cs @@ -1,16 +1,10 @@ -using Discord; -using Discord.WebSocket; -using NadekoBot.Common; -using NadekoBot.Common.ModuleBehaviors; -using NadekoBot.Services; +using NadekoBot.Common.ModuleBehaviors; using NadekoBot.Services.Database.Models; using NadekoBot.Extensions; using NadekoBot.Modules.CustomReactions.Extensions; using NadekoBot.Modules.Permissions.Common; using NadekoBot.Modules.Permissions.Services; -using System.Collections.Concurrent; using System.Runtime.CompilerServices; -using System.Threading.Tasks; using Microsoft.EntityFrameworkCore; using NadekoBot.Common.Yml; using NadekoBot.Db; diff --git a/src/NadekoBot/Modules/Gambling/AnimalRacingCommands.cs b/src/NadekoBot/Modules/Gambling/AnimalRacingCommands.cs index 72e63350d..94e4b073d 100644 --- a/src/NadekoBot/Modules/Gambling/AnimalRacingCommands.cs +++ b/src/NadekoBot/Modules/Gambling/AnimalRacingCommands.cs @@ -1,11 +1,4 @@ -using System.Threading.Tasks; -using Discord; -using Discord.Commands; -using Discord.WebSocket; -using NadekoBot.Common.Attributes; -using NadekoBot.Common; -using NadekoBot.Services; -using NadekoBot.Modules.Gambling.Common; +using NadekoBot.Modules.Gambling.Common; using NadekoBot.Modules.Gambling.Common.AnimalRacing; using NadekoBot.Modules.Gambling.Services; using NadekoBot.Extensions; diff --git a/src/NadekoBot/Modules/Gambling/BlackJackCommands.cs b/src/NadekoBot/Modules/Gambling/BlackJackCommands.cs index 9d6ca7a19..a8865199e 100644 --- a/src/NadekoBot/Modules/Gambling/BlackJackCommands.cs +++ b/src/NadekoBot/Modules/Gambling/BlackJackCommands.cs @@ -1,13 +1,7 @@ -using Discord; -using Discord.Commands; -using NadekoBot.Common.Attributes; -using NadekoBot.Common; -using NadekoBot.Modules.Gambling.Common; +using NadekoBot.Modules.Gambling.Common; using NadekoBot.Modules.Gambling.Common.Blackjack; using NadekoBot.Modules.Gambling.Services; using NadekoBot.Extensions; -using System.Threading.Tasks; -using NadekoBot.Services; namespace NadekoBot.Modules.Gambling; diff --git a/src/NadekoBot/Modules/Gambling/Common/AnimalRacing/AnimalRace.cs b/src/NadekoBot/Modules/Gambling/Common/AnimalRacing/AnimalRace.cs index 171e20978..c1f66424f 100644 --- a/src/NadekoBot/Modules/Gambling/Common/AnimalRacing/AnimalRace.cs +++ b/src/NadekoBot/Modules/Gambling/Common/AnimalRacing/AnimalRace.cs @@ -1,8 +1,4 @@ -using System.Threading; -using System.Threading.Tasks; -using NadekoBot.Common; -using NadekoBot.Services; -using NadekoBot.Extensions; +using NadekoBot.Extensions; using NadekoBot.Modules.Gambling.Common.AnimalRacing.Exceptions; using NadekoBot.Modules.Games.Common; diff --git a/src/NadekoBot/Modules/Gambling/Common/AnimalRacing/RaceOptions.cs b/src/NadekoBot/Modules/Gambling/Common/AnimalRacing/RaceOptions.cs index 19121f37b..c5d660b62 100644 --- a/src/NadekoBot/Modules/Gambling/Common/AnimalRacing/RaceOptions.cs +++ b/src/NadekoBot/Modules/Gambling/Common/AnimalRacing/RaceOptions.cs @@ -1,5 +1,4 @@ using CommandLine; -using NadekoBot.Common; namespace NadekoBot.Modules.Gambling.Common.AnimalRacing; diff --git a/src/NadekoBot/Modules/Gambling/Common/Blackjack/Blackjack.cs b/src/NadekoBot/Modules/Gambling/Common/Blackjack/Blackjack.cs index 26455875f..fad6161a7 100644 --- a/src/NadekoBot/Modules/Gambling/Common/Blackjack/Blackjack.cs +++ b/src/NadekoBot/Modules/Gambling/Common/Blackjack/Blackjack.cs @@ -1,9 +1,4 @@ -using System.Threading; -using System.Threading.Tasks; -using Discord; -using NadekoBot.Services; - -namespace NadekoBot.Modules.Gambling.Common.Blackjack; +namespace NadekoBot.Modules.Gambling.Common.Blackjack; public class Blackjack { diff --git a/src/NadekoBot/Modules/Gambling/Common/Blackjack/Player.cs b/src/NadekoBot/Modules/Gambling/Common/Blackjack/Player.cs index 2640548da..f04ec58ac 100644 --- a/src/NadekoBot/Modules/Gambling/Common/Blackjack/Player.cs +++ b/src/NadekoBot/Modules/Gambling/Common/Blackjack/Player.cs @@ -1,6 +1,4 @@ -using Discord; - -namespace NadekoBot.Modules.Gambling.Common.Blackjack; +namespace NadekoBot.Modules.Gambling.Common.Blackjack; public abstract class Player { diff --git a/src/NadekoBot/Modules/Gambling/Common/CurrencyRaffleGame.cs b/src/NadekoBot/Modules/Gambling/Common/CurrencyRaffleGame.cs index 9ed0ab9d9..e8a98b4e4 100644 --- a/src/NadekoBot/Modules/Gambling/Common/CurrencyRaffleGame.cs +++ b/src/NadekoBot/Modules/Gambling/Common/CurrencyRaffleGame.cs @@ -1,7 +1,4 @@ -using Discord; -using NadekoBot.Common; - -namespace NadekoBot.Modules.Gambling.Common; +namespace NadekoBot.Modules.Gambling.Common; public class CurrencyRaffleGame { diff --git a/src/NadekoBot/Modules/Gambling/Common/Deck.cs b/src/NadekoBot/Modules/Gambling/Common/Deck.cs index d8dd7a476..b95df630c 100644 --- a/src/NadekoBot/Modules/Gambling/Common/Deck.cs +++ b/src/NadekoBot/Modules/Gambling/Common/Deck.cs @@ -1,5 +1,4 @@ -using NadekoBot.Common; -using NadekoBot.Extensions; +using NadekoBot.Extensions; namespace NadekoBot.Modules.Gambling.Common; diff --git a/src/NadekoBot/Modules/Gambling/Common/Events/EventOptions.cs b/src/NadekoBot/Modules/Gambling/Common/Events/EventOptions.cs index 7bfd919fc..77cd6640a 100644 --- a/src/NadekoBot/Modules/Gambling/Common/Events/EventOptions.cs +++ b/src/NadekoBot/Modules/Gambling/Common/Events/EventOptions.cs @@ -1,5 +1,4 @@ using CommandLine; -using NadekoBot.Common; namespace NadekoBot.Modules.Gambling.Common.Events; diff --git a/src/NadekoBot/Modules/Gambling/Common/Events/GameStatusEvent.cs b/src/NadekoBot/Modules/Gambling/Common/Events/GameStatusEvent.cs index 0f64f649b..b60fafd16 100644 --- a/src/NadekoBot/Modules/Gambling/Common/Events/GameStatusEvent.cs +++ b/src/NadekoBot/Modules/Gambling/Common/Events/GameStatusEvent.cs @@ -1,12 +1,6 @@ -using Discord; -using Discord.WebSocket; -using NadekoBot.Common.Collections; -using NadekoBot.Services; +using NadekoBot.Common.Collections; using NadekoBot.Services.Database.Models; using NadekoBot.Extensions; -using System.Collections.Concurrent; -using System.Threading; -using System.Threading.Tasks; namespace NadekoBot.Modules.Gambling.Common.Events; diff --git a/src/NadekoBot/Modules/Gambling/Common/Events/ICurrencyEvent.cs b/src/NadekoBot/Modules/Gambling/Common/Events/ICurrencyEvent.cs index fb5db3ffc..1b4a1e1ad 100644 --- a/src/NadekoBot/Modules/Gambling/Common/Events/ICurrencyEvent.cs +++ b/src/NadekoBot/Modules/Gambling/Common/Events/ICurrencyEvent.cs @@ -1,6 +1,4 @@ -using System.Threading.Tasks; - -namespace NadekoBot.Modules.Gambling.Common; +namespace NadekoBot.Modules.Gambling.Common; public interface ICurrencyEvent { diff --git a/src/NadekoBot/Modules/Gambling/Common/Events/ReactionEvent.cs b/src/NadekoBot/Modules/Gambling/Common/Events/ReactionEvent.cs index f219dedda..b344e9972 100644 --- a/src/NadekoBot/Modules/Gambling/Common/Events/ReactionEvent.cs +++ b/src/NadekoBot/Modules/Gambling/Common/Events/ReactionEvent.cs @@ -1,12 +1,6 @@ -using Discord; -using Discord.WebSocket; -using NadekoBot.Common.Collections; -using NadekoBot.Services; +using NadekoBot.Common.Collections; using NadekoBot.Services.Database.Models; using NadekoBot.Extensions; -using System.Collections.Concurrent; -using System.Threading; -using System.Threading.Tasks; namespace NadekoBot.Modules.Gambling.Common.Events; diff --git a/src/NadekoBot/Modules/Gambling/Common/GamblingConfig.cs b/src/NadekoBot/Modules/Gambling/Common/GamblingConfig.cs index 2f1cc00da..6837f97b8 100644 --- a/src/NadekoBot/Modules/Gambling/Common/GamblingConfig.cs +++ b/src/NadekoBot/Modules/Gambling/Common/GamblingConfig.cs @@ -1,5 +1,4 @@ using Cloneable; -using NadekoBot.Common; using NadekoBot.Common.Yml; using SixLabors.ImageSharp.PixelFormats; using YamlDotNet.Serialization; diff --git a/src/NadekoBot/Modules/Gambling/Common/GamblingTopLevelModule.cs b/src/NadekoBot/Modules/Gambling/Common/GamblingTopLevelModule.cs index 5acb7ff9b..73e268085 100644 --- a/src/NadekoBot/Modules/Gambling/Common/GamblingTopLevelModule.cs +++ b/src/NadekoBot/Modules/Gambling/Common/GamblingTopLevelModule.cs @@ -1,6 +1,4 @@ -using Discord; -using System.Threading.Tasks; -using NadekoBot.Modules.Gambling.Services; +using NadekoBot.Modules.Gambling.Services; namespace NadekoBot.Modules.Gambling.Common; diff --git a/src/NadekoBot/Modules/Gambling/Common/RollDuelGame.cs b/src/NadekoBot/Modules/Gambling/Common/RollDuelGame.cs index c8b4b6683..a54ef451e 100644 --- a/src/NadekoBot/Modules/Gambling/Common/RollDuelGame.cs +++ b/src/NadekoBot/Modules/Gambling/Common/RollDuelGame.cs @@ -1,9 +1,4 @@ -using NadekoBot.Common; -using NadekoBot.Services; -using System.Threading; -using System.Threading.Tasks; - -namespace NadekoBot.Modules.Gambling.Common; +namespace NadekoBot.Modules.Gambling.Common; public class RollDuelGame { diff --git a/src/NadekoBot/Modules/Gambling/Common/Slot/SlotGame.cs b/src/NadekoBot/Modules/Gambling/Common/Slot/SlotGame.cs index c0334405f..6258cd9b0 100644 --- a/src/NadekoBot/Modules/Gambling/Common/Slot/SlotGame.cs +++ b/src/NadekoBot/Modules/Gambling/Common/Slot/SlotGame.cs @@ -1,6 +1,4 @@ -using NadekoBot.Common; - -namespace NadekoBot.Modules.Gambling.Common.Slot; +namespace NadekoBot.Modules.Gambling.Common.Slot; public class SlotGame { diff --git a/src/NadekoBot/Modules/Gambling/Common/WheelOfFortune/WheelOfFortune.cs b/src/NadekoBot/Modules/Gambling/Common/WheelOfFortune/WheelOfFortune.cs index 7b9d4ea72..4f8b9f39d 100644 --- a/src/NadekoBot/Modules/Gambling/Common/WheelOfFortune/WheelOfFortune.cs +++ b/src/NadekoBot/Modules/Gambling/Common/WheelOfFortune/WheelOfFortune.cs @@ -1,8 +1,4 @@ -using System.Threading.Tasks; -using NadekoBot.Common; -using NadekoBot.Services; - -namespace NadekoBot.Modules.Gambling.Common.WheelOfFortune; +namespace NadekoBot.Modules.Gambling.Common.WheelOfFortune; public class WheelOfFortuneGame { diff --git a/src/NadekoBot/Modules/Gambling/Connect4/Connect4.cs b/src/NadekoBot/Modules/Gambling/Connect4/Connect4.cs index 82430ff0b..04f3b84bd 100644 --- a/src/NadekoBot/Modules/Gambling/Connect4/Connect4.cs +++ b/src/NadekoBot/Modules/Gambling/Connect4/Connect4.cs @@ -1,9 +1,5 @@ using CommandLine; -using NadekoBot.Common; -using NadekoBot.Services; using System.Collections.Immutable; -using System.Threading; -using System.Threading.Tasks; namespace NadekoBot.Modules.Gambling.Common.Connect4; diff --git a/src/NadekoBot/Modules/Gambling/Connect4Commands.cs b/src/NadekoBot/Modules/Gambling/Connect4Commands.cs index 9d50a4dce..41651e5bb 100644 --- a/src/NadekoBot/Modules/Gambling/Connect4Commands.cs +++ b/src/NadekoBot/Modules/Gambling/Connect4Commands.cs @@ -1,15 +1,8 @@ -using Discord; -using Discord.Commands; -using Discord.WebSocket; -using NadekoBot.Common.Attributes; -using NadekoBot.Modules.Gambling.Common; +using NadekoBot.Modules.Gambling.Common; using NadekoBot.Extensions; using NadekoBot.Modules.Gambling.Common.Connect4; using NadekoBot.Modules.Gambling.Services; using System.Text; -using System.Threading.Tasks; -using NadekoBot.Common; -using NadekoBot.Services; namespace NadekoBot.Modules.Gambling; diff --git a/src/NadekoBot/Modules/Gambling/CurrencyEventsCommands.cs b/src/NadekoBot/Modules/Gambling/CurrencyEventsCommands.cs index 61f6892e6..fbd539a36 100644 --- a/src/NadekoBot/Modules/Gambling/CurrencyEventsCommands.cs +++ b/src/NadekoBot/Modules/Gambling/CurrencyEventsCommands.cs @@ -1,11 +1,6 @@ -using Discord; -using Discord.Commands; -using NadekoBot.Extensions; -using System.Threading.Tasks; -using NadekoBot.Common.Attributes; +using NadekoBot.Extensions; using NadekoBot.Modules.Gambling.Services; using NadekoBot.Modules.Gambling.Common.Events; -using NadekoBot.Common; using NadekoBot.Services.Database.Models; using NadekoBot.Modules.Gambling.Common; diff --git a/src/NadekoBot/Modules/Gambling/CurrencyRaffleCommands.cs b/src/NadekoBot/Modules/Gambling/CurrencyRaffleCommands.cs index 94ec03f2e..4029aea8a 100644 --- a/src/NadekoBot/Modules/Gambling/CurrencyRaffleCommands.cs +++ b/src/NadekoBot/Modules/Gambling/CurrencyRaffleCommands.cs @@ -1,10 +1,5 @@ -using NadekoBot.Common.Attributes; -using NadekoBot.Modules.Gambling.Services; -using System.Threading.Tasks; -using Discord; -using Discord.Commands; +using NadekoBot.Modules.Gambling.Services; using NadekoBot.Modules.Gambling.Common; -using NadekoBot.Common; namespace NadekoBot.Modules.Gambling; diff --git a/src/NadekoBot/Modules/Gambling/DiceRollCommands.cs b/src/NadekoBot/Modules/Gambling/DiceRollCommands.cs index b93f56fac..71512c146 100644 --- a/src/NadekoBot/Modules/Gambling/DiceRollCommands.cs +++ b/src/NadekoBot/Modules/Gambling/DiceRollCommands.cs @@ -1,13 +1,7 @@ -using Discord; -using Discord.Commands; -using NadekoBot.Common; -using NadekoBot.Common.Attributes; using NadekoBot.Extensions; using SixLabors.ImageSharp; using SixLabors.ImageSharp.PixelFormats; using System.Text.RegularExpressions; -using System.Threading.Tasks; -using NadekoBot.Services; using Image = SixLabors.ImageSharp.Image; namespace NadekoBot.Modules.Gambling; diff --git a/src/NadekoBot/Modules/Gambling/DrawCommands.cs b/src/NadekoBot/Modules/Gambling/DrawCommands.cs index 9e5a6977b..c8c1d644f 100644 --- a/src/NadekoBot/Modules/Gambling/DrawCommands.cs +++ b/src/NadekoBot/Modules/Gambling/DrawCommands.cs @@ -1,11 +1,4 @@ -using Discord; -using Discord.Commands; -using NadekoBot.Extensions; -using System.Collections.Concurrent; -using System.IO; -using System.Threading.Tasks; -using NadekoBot.Common.Attributes; -using NadekoBot.Services; +using NadekoBot.Extensions; using NadekoBot.Modules.Gambling.Common; using Image = SixLabors.ImageSharp.Image; using SixLabors.ImageSharp; diff --git a/src/NadekoBot/Modules/Gambling/FlipCoinCommands.cs b/src/NadekoBot/Modules/Gambling/FlipCoinCommands.cs index 97eeafd17..95050fe73 100644 --- a/src/NadekoBot/Modules/Gambling/FlipCoinCommands.cs +++ b/src/NadekoBot/Modules/Gambling/FlipCoinCommands.cs @@ -1,14 +1,8 @@ -using Discord; -using Discord.Commands; -using NadekoBot.Common; -using NadekoBot.Common.Attributes; using NadekoBot.Modules.Gambling.Common; using NadekoBot.Extensions; using NadekoBot.Modules.Gambling.Services; using SixLabors.ImageSharp; using SixLabors.ImageSharp.PixelFormats; -using System.Threading.Tasks; -using NadekoBot.Services; using Image = SixLabors.ImageSharp.Image; namespace NadekoBot.Modules.Gambling; diff --git a/src/NadekoBot/Modules/Gambling/Gambling.cs b/src/NadekoBot/Modules/Gambling/Gambling.cs index cf5547cfe..64da8ef3f 100644 --- a/src/NadekoBot/Modules/Gambling/Gambling.cs +++ b/src/NadekoBot/Modules/Gambling/Gambling.cs @@ -1,16 +1,9 @@ -using Discord; -using Discord.Commands; -using Discord.WebSocket; -using NadekoBot.Common; -using NadekoBot.Common.Attributes; using NadekoBot.Modules.Gambling.Common; using NadekoBot.Db.Models; using NadekoBot.Extensions; using NadekoBot.Modules.Gambling.Services; using System.Globalization; using System.Numerics; -using System.Threading.Tasks; -using NadekoBot.Services; using NadekoBot.Services.Database.Models; using NadekoBot.Db; diff --git a/src/NadekoBot/Modules/Gambling/PlantAndPickCommands.cs b/src/NadekoBot/Modules/Gambling/PlantAndPickCommands.cs index dd29d57d8..343358b00 100644 --- a/src/NadekoBot/Modules/Gambling/PlantAndPickCommands.cs +++ b/src/NadekoBot/Modules/Gambling/PlantAndPickCommands.cs @@ -1,13 +1,7 @@ -using Discord; -using Discord.Commands; -using Discord.WebSocket; -using NadekoBot.Common.Attributes; using NadekoBot.Extensions; using NadekoBot.Modules.Administration.Services; using NadekoBot.Modules.Gambling.Services; -using System.Threading.Tasks; using NadekoBot.Modules.Gambling.Common; -using NadekoBot.Common; namespace NadekoBot.Modules.Gambling; diff --git a/src/NadekoBot/Modules/Gambling/Services/AnimalRaceService.cs b/src/NadekoBot/Modules/Gambling/Services/AnimalRaceService.cs index e76ecc35f..887dc1e22 100644 --- a/src/NadekoBot/Modules/Gambling/Services/AnimalRaceService.cs +++ b/src/NadekoBot/Modules/Gambling/Services/AnimalRaceService.cs @@ -1,6 +1,4 @@ -using NadekoBot.Services; -using System.Collections.Concurrent; -using NadekoBot.Modules.Gambling.Common.AnimalRacing; +using NadekoBot.Modules.Gambling.Common.AnimalRacing; namespace NadekoBot.Modules.Gambling.Services; diff --git a/src/NadekoBot/Modules/Gambling/Services/BlackJackService.cs b/src/NadekoBot/Modules/Gambling/Services/BlackJackService.cs index 7bb5afcbe..81c4fc8e1 100644 --- a/src/NadekoBot/Modules/Gambling/Services/BlackJackService.cs +++ b/src/NadekoBot/Modules/Gambling/Services/BlackJackService.cs @@ -1,6 +1,4 @@ using NadekoBot.Modules.Gambling.Common.Blackjack; -using NadekoBot.Services; -using System.Collections.Concurrent; namespace NadekoBot.Modules.Gambling.Services; diff --git a/src/NadekoBot/Modules/Gambling/Services/CurrencyEventsService.cs b/src/NadekoBot/Modules/Gambling/Services/CurrencyEventsService.cs index 9889bd7e7..069d81aa8 100644 --- a/src/NadekoBot/Modules/Gambling/Services/CurrencyEventsService.cs +++ b/src/NadekoBot/Modules/Gambling/Services/CurrencyEventsService.cs @@ -1,9 +1,5 @@ -using NadekoBot.Services; -using NadekoBot.Modules.Gambling.Common.Events; -using System.Collections.Concurrent; +using NadekoBot.Modules.Gambling.Common.Events; using NadekoBot.Modules.Gambling.Common; -using Discord.WebSocket; -using System.Threading.Tasks; using NadekoBot.Services.Database.Models; namespace NadekoBot.Modules.Gambling.Services; diff --git a/src/NadekoBot/Modules/Gambling/Services/CurrencyRaffleService.cs b/src/NadekoBot/Modules/Gambling/Services/CurrencyRaffleService.cs index 2b8917c43..f68020676 100644 --- a/src/NadekoBot/Modules/Gambling/Services/CurrencyRaffleService.cs +++ b/src/NadekoBot/Modules/Gambling/Services/CurrencyRaffleService.cs @@ -1,8 +1,4 @@ -using System.Threading.Tasks; -using NadekoBot.Services; -using NadekoBot.Modules.Gambling.Common; -using System.Threading; -using Discord; +using NadekoBot.Modules.Gambling.Common; namespace NadekoBot.Modules.Gambling.Services; diff --git a/src/NadekoBot/Modules/Gambling/Services/GamblingConfigService.cs b/src/NadekoBot/Modules/Gambling/Services/GamblingConfigService.cs index 195f31608..020ae1c9d 100644 --- a/src/NadekoBot/Modules/Gambling/Services/GamblingConfigService.cs +++ b/src/NadekoBot/Modules/Gambling/Services/GamblingConfigService.cs @@ -1,7 +1,5 @@ -using NadekoBot.Common; -using NadekoBot.Common.Configs; +using NadekoBot.Common.Configs; using NadekoBot.Modules.Gambling.Common; -using NadekoBot.Services; namespace NadekoBot.Modules.Gambling.Services; diff --git a/src/NadekoBot/Modules/Gambling/Services/GamblingService.cs b/src/NadekoBot/Modules/Gambling/Services/GamblingService.cs index 6067e18bd..0da8be086 100644 --- a/src/NadekoBot/Modules/Gambling/Services/GamblingService.cs +++ b/src/NadekoBot/Modules/Gambling/Services/GamblingService.cs @@ -1,12 +1,7 @@ -using Discord.WebSocket; -using NadekoBot.Modules.Gambling.Common; -using NadekoBot.Services; +using NadekoBot.Modules.Gambling.Common; using NadekoBot.Modules.Gambling.Common.Connect4; using NadekoBot.Modules.Gambling.Common.WheelOfFortune; using Newtonsoft.Json; -using System.Collections.Concurrent; -using System.Threading; -using System.Threading.Tasks; using Microsoft.EntityFrameworkCore; using NadekoBot.Db; using NadekoBot.Modules.Gambling.Common.Slot; diff --git a/src/NadekoBot/Modules/Gambling/Services/IShopService.cs b/src/NadekoBot/Modules/Gambling/Services/IShopService.cs index b261013f1..65afeec15 100644 --- a/src/NadekoBot/Modules/Gambling/Services/IShopService.cs +++ b/src/NadekoBot/Modules/Gambling/Services/IShopService.cs @@ -1,6 +1,4 @@ -using System.Threading.Tasks; - -namespace NadekoBot.Modules.Gambling.Services; +namespace NadekoBot.Modules.Gambling.Services; public interface IShopService { diff --git a/src/NadekoBot/Modules/Gambling/Services/Impl/ShopService.cs b/src/NadekoBot/Modules/Gambling/Services/Impl/ShopService.cs index db8717640..460685528 100644 --- a/src/NadekoBot/Modules/Gambling/Services/Impl/ShopService.cs +++ b/src/NadekoBot/Modules/Gambling/Services/Impl/ShopService.cs @@ -1,7 +1,5 @@ -using System.Threading.Tasks; -using Microsoft.EntityFrameworkCore; +using Microsoft.EntityFrameworkCore; using NadekoBot.Common.Collections; -using NadekoBot.Services; using NadekoBot.Services.Database; using NadekoBot.Services.Database.Models; using NadekoBot.Db; diff --git a/src/NadekoBot/Modules/Gambling/Services/PlantPickService.cs b/src/NadekoBot/Modules/Gambling/Services/PlantPickService.cs index 41c1bb92f..9f8e199f8 100644 --- a/src/NadekoBot/Modules/Gambling/Services/PlantPickService.cs +++ b/src/NadekoBot/Modules/Gambling/Services/PlantPickService.cs @@ -1,9 +1,5 @@ -using Discord; -using Discord.WebSocket; -using Microsoft.EntityFrameworkCore; -using NadekoBot.Common; +using Microsoft.EntityFrameworkCore; using NadekoBot.Common.Collections; -using NadekoBot.Services; using NadekoBot.Services.Database.Models; using NadekoBot.Extensions; using SixLabors.Fonts; @@ -11,10 +7,6 @@ using SixLabors.ImageSharp; using SixLabors.ImageSharp.Drawing.Processing; using SixLabors.ImageSharp.PixelFormats; using SixLabors.ImageSharp.Processing; -using System.Collections.Concurrent; -using System.IO; -using System.Threading; -using System.Threading.Tasks; using NadekoBot.Db; using Image = SixLabors.ImageSharp.Image; using Color = SixLabors.ImageSharp.Color; diff --git a/src/NadekoBot/Modules/Gambling/Services/VoteRewardService.cs b/src/NadekoBot/Modules/Gambling/Services/VoteRewardService.cs index 4cc303697..e93a0e611 100644 --- a/src/NadekoBot/Modules/Gambling/Services/VoteRewardService.cs +++ b/src/NadekoBot/Modules/Gambling/Services/VoteRewardService.cs @@ -1,10 +1,6 @@ -using System.Net.Http; -using System.Text.Json; +using System.Text.Json; using System.Text.Json.Serialization; -using System.Threading.Tasks; using NadekoBot.Common.ModuleBehaviors; -using NadekoBot.Services; -using Discord.WebSocket; namespace NadekoBot.Modules.Gambling.Services; diff --git a/src/NadekoBot/Modules/Gambling/Services/WaifuService.cs b/src/NadekoBot/Modules/Gambling/Services/WaifuService.cs index 1185e986d..1185ee119 100644 --- a/src/NadekoBot/Modules/Gambling/Services/WaifuService.cs +++ b/src/NadekoBot/Modules/Gambling/Services/WaifuService.cs @@ -1,8 +1,5 @@ -using Discord; -using NadekoBot.Modules.Gambling.Common.Waifu; -using NadekoBot.Services; +using NadekoBot.Modules.Gambling.Common.Waifu; using NadekoBot.Services.Database.Models; -using System.Threading.Tasks; using Microsoft.EntityFrameworkCore; using NadekoBot.Db; using NadekoBot.Modules.Gambling.Common; diff --git a/src/NadekoBot/Modules/Gambling/ShopCommands.cs b/src/NadekoBot/Modules/Gambling/ShopCommands.cs index b23092ca8..2ae54c657 100644 --- a/src/NadekoBot/Modules/Gambling/ShopCommands.cs +++ b/src/NadekoBot/Modules/Gambling/ShopCommands.cs @@ -1,13 +1,7 @@ -using System.Threading.Tasks; -using Discord; -using Discord.Commands; -using Microsoft.EntityFrameworkCore; -using NadekoBot.Common; -using NadekoBot.Common.Attributes; +using Microsoft.EntityFrameworkCore; using NadekoBot.Common.Collections; using NadekoBot.Modules.Gambling.Common; using NadekoBot.Modules.Gambling.Services; -using NadekoBot.Services; using NadekoBot.Services.Database.Models; using NadekoBot.Db; using NadekoBot.Extensions; diff --git a/src/NadekoBot/Modules/Gambling/SlotCommands.cs b/src/NadekoBot/Modules/Gambling/SlotCommands.cs index a85fc7557..c36335a0a 100644 --- a/src/NadekoBot/Modules/Gambling/SlotCommands.cs +++ b/src/NadekoBot/Modules/Gambling/SlotCommands.cs @@ -1,15 +1,8 @@ -using Discord; -using Discord.Commands; -using NadekoBot.Extensions; +using NadekoBot.Extensions; using System.Text; -using System.Threading; -using System.Threading.Tasks; -using NadekoBot.Common; -using NadekoBot.Common.Attributes; using NadekoBot.Db.Models; using NadekoBot.Modules.Gambling.Services; using NadekoBot.Modules.Gambling.Common; -using NadekoBot.Services; using SixLabors.Fonts; using Image = SixLabors.ImageSharp.Image; using SixLabors.ImageSharp.Processing; diff --git a/src/NadekoBot/Modules/Gambling/WaifuClaimCommands.cs b/src/NadekoBot/Modules/Gambling/WaifuClaimCommands.cs index d1a13b58e..3831b06bc 100644 --- a/src/NadekoBot/Modules/Gambling/WaifuClaimCommands.cs +++ b/src/NadekoBot/Modules/Gambling/WaifuClaimCommands.cs @@ -1,10 +1,6 @@ -using Discord; -using Discord.Commands; -using NadekoBot.Common.Attributes; -using NadekoBot.Modules.Gambling.Common.Waifu; +using NadekoBot.Modules.Gambling.Common.Waifu; using NadekoBot.Extensions; using NadekoBot.Modules.Gambling.Services; -using System.Threading.Tasks; using NadekoBot.Modules.Gambling.Common; namespace NadekoBot.Modules.Gambling; diff --git a/src/NadekoBot/Modules/Gambling/WheelOfFortuneCommands.cs b/src/NadekoBot/Modules/Gambling/WheelOfFortuneCommands.cs index 1fd469db9..6dcf2d7cf 100644 --- a/src/NadekoBot/Modules/Gambling/WheelOfFortuneCommands.cs +++ b/src/NadekoBot/Modules/Gambling/WheelOfFortuneCommands.cs @@ -1,12 +1,7 @@ -using Discord; -using NadekoBot.Common.Attributes; -using System.Threading.Tasks; -using Wof = NadekoBot.Modules.Gambling.Common.WheelOfFortune.WheelOfFortuneGame; +using Wof = NadekoBot.Modules.Gambling.Common.WheelOfFortune.WheelOfFortuneGame; using NadekoBot.Modules.Gambling.Services; using NadekoBot.Modules.Gambling.Common; using System.Collections.Immutable; -using NadekoBot.Common; -using NadekoBot.Services; namespace NadekoBot.Modules.Gambling; diff --git a/src/NadekoBot/Modules/Games/AcropobiaCommands.cs b/src/NadekoBot/Modules/Games/AcropobiaCommands.cs index b39b1792d..56aee8df5 100644 --- a/src/NadekoBot/Modules/Games/AcropobiaCommands.cs +++ b/src/NadekoBot/Modules/Games/AcropobiaCommands.cs @@ -1,13 +1,7 @@ -using Discord; -using Discord.Commands; -using Discord.WebSocket; -using NadekoBot.Extensions; +using NadekoBot.Extensions; using System.Collections.Immutable; -using System.Threading.Tasks; -using NadekoBot.Common.Attributes; using NadekoBot.Modules.Games.Common.Acrophobia; using NadekoBot.Modules.Games.Services; -using NadekoBot.Common; namespace NadekoBot.Modules.Games; diff --git a/src/NadekoBot/Modules/Games/CleverBotCommands.cs b/src/NadekoBot/Modules/Games/CleverBotCommands.cs index 285898dbd..6d4db9627 100644 --- a/src/NadekoBot/Modules/Games/CleverBotCommands.cs +++ b/src/NadekoBot/Modules/Games/CleverBotCommands.cs @@ -1,12 +1,5 @@ -using Discord; -using Discord.Commands; -using System.Threading.Tasks; -using NadekoBot.Common; -using NadekoBot.Common.Attributes; -using NadekoBot.Services; -using NadekoBot.Db; +using NadekoBot.Db; using NadekoBot.Modules.Games.Services; -using NadekoBot.Modules.Games.Common.ChatterBot; namespace NadekoBot.Modules.Games; diff --git a/src/NadekoBot/Modules/Games/Common/Acrophobia/Acrophobia.cs b/src/NadekoBot/Modules/Games/Common/Acrophobia/Acrophobia.cs index 7891174dd..dfa18d0d2 100644 --- a/src/NadekoBot/Modules/Games/Common/Acrophobia/Acrophobia.cs +++ b/src/NadekoBot/Modules/Games/Common/Acrophobia/Acrophobia.cs @@ -1,8 +1,5 @@ using System.Collections.Immutable; -using System.Threading; -using System.Threading.Tasks; using CommandLine; -using NadekoBot.Common; using NadekoBot.Extensions; namespace NadekoBot.Modules.Games.Common.Acrophobia; diff --git a/src/NadekoBot/Modules/Games/Common/ChatterBot/ChatterBotSession.cs b/src/NadekoBot/Modules/Games/Common/ChatterBot/ChatterBotSession.cs index a84695169..625972683 100644 --- a/src/NadekoBot/Modules/Games/Common/ChatterBot/ChatterBotSession.cs +++ b/src/NadekoBot/Modules/Games/Common/ChatterBot/ChatterBotSession.cs @@ -1,7 +1,4 @@ -using System.Net.Http; -using System.Threading.Tasks; -using NadekoBot.Common; -using NadekoBot.Extensions; +using NadekoBot.Extensions; using Newtonsoft.Json; namespace NadekoBot.Modules.Games.Common.ChatterBot; diff --git a/src/NadekoBot/Modules/Games/Common/ChatterBot/IChatterBotSession.cs b/src/NadekoBot/Modules/Games/Common/ChatterBot/IChatterBotSession.cs index 97fbdb8c0..f8517b48f 100644 --- a/src/NadekoBot/Modules/Games/Common/ChatterBot/IChatterBotSession.cs +++ b/src/NadekoBot/Modules/Games/Common/ChatterBot/IChatterBotSession.cs @@ -1,6 +1,4 @@ -using System.Threading.Tasks; - -namespace NadekoBot.Modules.Games.Common.ChatterBot; +namespace NadekoBot.Modules.Games.Common.ChatterBot; public interface IChatterBotSession { diff --git a/src/NadekoBot/Modules/Games/Common/ChatterBot/OfficialCleverbotSession.cs b/src/NadekoBot/Modules/Games/Common/ChatterBot/OfficialCleverbotSession.cs index 18bd81648..daf5fb30c 100644 --- a/src/NadekoBot/Modules/Games/Common/ChatterBot/OfficialCleverbotSession.cs +++ b/src/NadekoBot/Modules/Games/Common/ChatterBot/OfficialCleverbotSession.cs @@ -1,7 +1,4 @@ -using NadekoBot.Common; -using Newtonsoft.Json; -using System.Net.Http; -using System.Threading.Tasks; +using Newtonsoft.Json; namespace NadekoBot.Modules.Games.Common.ChatterBot; diff --git a/src/NadekoBot/Modules/Games/Common/GamesConfig.cs b/src/NadekoBot/Modules/Games/Common/GamesConfig.cs index ef3e06154..146a66a95 100644 --- a/src/NadekoBot/Modules/Games/Common/GamesConfig.cs +++ b/src/NadekoBot/Modules/Games/Common/GamesConfig.cs @@ -1,5 +1,4 @@ using Cloneable; -using NadekoBot.Common; using NadekoBot.Common.Yml; namespace NadekoBot.Modules.Games.Common; diff --git a/src/NadekoBot/Modules/Games/Common/GirlRating.cs b/src/NadekoBot/Modules/Games/Common/GirlRating.cs index 11e7bafb8..ddbf28e41 100644 --- a/src/NadekoBot/Modules/Games/Common/GirlRating.cs +++ b/src/NadekoBot/Modules/Games/Common/GirlRating.cs @@ -1,8 +1,4 @@ -using System.IO; -using System.Net.Http; -using NadekoBot.Common; -using NadekoBot.Services; -using Image = SixLabors.ImageSharp.Image; +using Image = SixLabors.ImageSharp.Image; using SixLabors.ImageSharp; using SixLabors.ImageSharp.Processing; diff --git a/src/NadekoBot/Modules/Games/Common/Hangman/DefaultHangmanSource.cs b/src/NadekoBot/Modules/Games/Common/Hangman/DefaultHangmanSource.cs index f606ed771..4321128d9 100644 --- a/src/NadekoBot/Modules/Games/Common/Hangman/DefaultHangmanSource.cs +++ b/src/NadekoBot/Modules/Games/Common/Hangman/DefaultHangmanSource.cs @@ -1,7 +1,5 @@ #nullable enable using System.Diagnostics.CodeAnalysis; -using System.IO; -using NadekoBot.Common; using NadekoBot.Common.Yml; namespace NadekoBot.Modules.Games.Hangman; diff --git a/src/NadekoBot/Modules/Games/Common/Hangman/HangmanService.cs b/src/NadekoBot/Modules/Games/Common/Hangman/HangmanService.cs index 1273afbe8..893b53370 100644 --- a/src/NadekoBot/Modules/Games/Common/Hangman/HangmanService.cs +++ b/src/NadekoBot/Modules/Games/Common/Hangman/HangmanService.cs @@ -1,13 +1,9 @@ #nullable enable -using System.Collections.Concurrent; using System.Diagnostics.CodeAnalysis; -using System.Threading.Tasks; -using Discord; using Microsoft.Extensions.Caching.Memory; using NadekoBot.Common.ModuleBehaviors; using NadekoBot.Extensions; using NadekoBot.Modules.Games.Services; -using NadekoBot.Services; namespace NadekoBot.Modules.Games.Hangman; diff --git a/src/NadekoBot/Modules/Games/Common/Hangman/IHangmanService.cs b/src/NadekoBot/Modules/Games/Common/Hangman/IHangmanService.cs index 1e63a7bbd..6ec92bc28 100644 --- a/src/NadekoBot/Modules/Games/Common/Hangman/IHangmanService.cs +++ b/src/NadekoBot/Modules/Games/Common/Hangman/IHangmanService.cs @@ -1,6 +1,5 @@ #nullable enable using System.Diagnostics.CodeAnalysis; -using System.Threading.Tasks; namespace NadekoBot.Modules.Games.Hangman; diff --git a/src/NadekoBot/Modules/Games/Common/Hangman/IHangmanSource.cs b/src/NadekoBot/Modules/Games/Common/Hangman/IHangmanSource.cs index 55913bce0..4b2469edc 100644 --- a/src/NadekoBot/Modules/Games/Common/Hangman/IHangmanSource.cs +++ b/src/NadekoBot/Modules/Games/Common/Hangman/IHangmanSource.cs @@ -1,6 +1,5 @@ #nullable enable using System.Diagnostics.CodeAnalysis; -using NadekoBot.Services; namespace NadekoBot.Modules.Games.Hangman; diff --git a/src/NadekoBot/Modules/Games/Common/Nunchi/Nunchi.cs b/src/NadekoBot/Modules/Games/Common/Nunchi/Nunchi.cs index 91c7a8e4d..9f75a6fa6 100644 --- a/src/NadekoBot/Modules/Games/Common/Nunchi/Nunchi.cs +++ b/src/NadekoBot/Modules/Games/Common/Nunchi/Nunchi.cs @@ -1,7 +1,4 @@ -using NadekoBot.Common; -using System.Collections.Immutable; -using System.Threading; -using System.Threading.Tasks; +using System.Collections.Immutable; namespace NadekoBot.Modules.Games.Common.Nunchi; diff --git a/src/NadekoBot/Modules/Games/Common/PollRunner.cs b/src/NadekoBot/Modules/Games/Common/PollRunner.cs index 35d6ca176..0e9edbf77 100644 --- a/src/NadekoBot/Modules/Games/Common/PollRunner.cs +++ b/src/NadekoBot/Modules/Games/Common/PollRunner.cs @@ -1,8 +1,4 @@ -using System.Threading.Tasks; -using Discord; -using System.Threading; -using NadekoBot.Services; -using NadekoBot.Services.Database.Models; +using NadekoBot.Services.Database.Models; namespace NadekoBot.Modules.Games.Common; diff --git a/src/NadekoBot/Modules/Games/Common/TicTacToe.cs b/src/NadekoBot/Modules/Games/Common/TicTacToe.cs index cf4a01c24..c715a84e1 100644 --- a/src/NadekoBot/Modules/Games/Common/TicTacToe.cs +++ b/src/NadekoBot/Modules/Games/Common/TicTacToe.cs @@ -1,12 +1,6 @@ -using Discord; -using Discord.WebSocket; -using NadekoBot.Extensions; +using NadekoBot.Extensions; using System.Text; -using System.Threading; -using System.Threading.Tasks; using CommandLine; -using NadekoBot.Common; -using NadekoBot.Services; namespace NadekoBot.Modules.Games.Common; diff --git a/src/NadekoBot/Modules/Games/Common/Trivia/TriviaGame.cs b/src/NadekoBot/Modules/Games/Common/Trivia/TriviaGame.cs index 5ccd8227e..bcfe9da03 100644 --- a/src/NadekoBot/Modules/Games/Common/Trivia/TriviaGame.cs +++ b/src/NadekoBot/Modules/Games/Common/Trivia/TriviaGame.cs @@ -1,12 +1,5 @@ -using System.Collections.Concurrent; -using System.Text; -using System.Threading; -using System.Threading.Tasks; -using Discord; -using Discord.Net; -using Discord.WebSocket; +using System.Text; using NadekoBot.Extensions; -using NadekoBot.Services; namespace NadekoBot.Modules.Games.Common.Trivia; diff --git a/src/NadekoBot/Modules/Games/Common/Trivia/TriviaOptions.cs b/src/NadekoBot/Modules/Games/Common/Trivia/TriviaOptions.cs index 00e634684..3f6faf785 100644 --- a/src/NadekoBot/Modules/Games/Common/Trivia/TriviaOptions.cs +++ b/src/NadekoBot/Modules/Games/Common/Trivia/TriviaOptions.cs @@ -1,5 +1,4 @@ using CommandLine; -using NadekoBot.Common; namespace NadekoBot.Modules.Games.Common.Trivia; diff --git a/src/NadekoBot/Modules/Games/Common/Trivia/TriviaQuestionPool.cs b/src/NadekoBot/Modules/Games/Common/Trivia/TriviaQuestionPool.cs index 9a484ea72..af82057a8 100644 --- a/src/NadekoBot/Modules/Games/Common/Trivia/TriviaQuestionPool.cs +++ b/src/NadekoBot/Modules/Games/Common/Trivia/TriviaQuestionPool.cs @@ -1,6 +1,4 @@ -using NadekoBot.Common; -using NadekoBot.Services; -using NadekoBot.Extensions; +using NadekoBot.Extensions; namespace NadekoBot.Modules.Games.Common.Trivia; diff --git a/src/NadekoBot/Modules/Games/Common/TypingGame.cs b/src/NadekoBot/Modules/Games/Common/TypingGame.cs index 9febbc840..ae75c3cb9 100644 --- a/src/NadekoBot/Modules/Games/Common/TypingGame.cs +++ b/src/NadekoBot/Modules/Games/Common/TypingGame.cs @@ -1,12 +1,7 @@ using System.Diagnostics; -using System.Threading.Tasks; -using Discord; -using Discord.WebSocket; -using NadekoBot.Common; using NadekoBot.Extensions; using NadekoBot.Modules.Games.Services; using CommandLine; -using NadekoBot.Services; namespace NadekoBot.Modules.Games.Common; diff --git a/src/NadekoBot/Modules/Games/Games.cs b/src/NadekoBot/Modules/Games/Games.cs index 2aeb7e06b..602a00e0d 100644 --- a/src/NadekoBot/Modules/Games/Games.cs +++ b/src/NadekoBot/Modules/Games/Games.cs @@ -1,14 +1,6 @@ -using Discord; -using Discord.Commands; -using NadekoBot.Common; -using NadekoBot.Common.Attributes; -using NadekoBot.Services; -using NadekoBot.Extensions; +using NadekoBot.Extensions; using NadekoBot.Modules.Games.Common; using NadekoBot.Modules.Games.Services; -using System.IO; -using System.Net.Http; -using System.Threading.Tasks; namespace NadekoBot.Modules.Games; diff --git a/src/NadekoBot/Modules/Games/HangmanCommands.cs b/src/NadekoBot/Modules/Games/HangmanCommands.cs index 95f61d44a..ec072328c 100644 --- a/src/NadekoBot/Modules/Games/HangmanCommands.cs +++ b/src/NadekoBot/Modules/Games/HangmanCommands.cs @@ -1,11 +1,6 @@ #nullable enable -using Discord.Commands; -using System.Threading.Tasks; -using Discord; -using NadekoBot.Common.Attributes; using NadekoBot.Extensions; using NadekoBot.Modules.Games.Hangman; -using NadekoBot.Services; namespace NadekoBot.Modules.Games; diff --git a/src/NadekoBot/Modules/Games/NunchiCommands.cs b/src/NadekoBot/Modules/Games/NunchiCommands.cs index e67b9b194..596a6b138 100644 --- a/src/NadekoBot/Modules/Games/NunchiCommands.cs +++ b/src/NadekoBot/Modules/Games/NunchiCommands.cs @@ -1,10 +1,5 @@ -using Discord; -using Discord.Commands; -using Discord.WebSocket; -using NadekoBot.Common.Attributes; -using NadekoBot.Modules.Games.Common.Nunchi; +using NadekoBot.Modules.Games.Common.Nunchi; using NadekoBot.Modules.Games.Services; -using System.Threading.Tasks; namespace NadekoBot.Modules.Games; diff --git a/src/NadekoBot/Modules/Games/PollCommands.cs b/src/NadekoBot/Modules/Games/PollCommands.cs index a804e5ac4..5d2f1ee5d 100644 --- a/src/NadekoBot/Modules/Games/PollCommands.cs +++ b/src/NadekoBot/Modules/Games/PollCommands.cs @@ -1,9 +1,4 @@ -using Discord; -using Discord.Commands; -using Discord.WebSocket; -using NadekoBot.Extensions; -using System.Threading.Tasks; -using NadekoBot.Common.Attributes; +using NadekoBot.Extensions; using NadekoBot.Modules.Games.Services; using NadekoBot.Services.Database.Models; using System.Text; diff --git a/src/NadekoBot/Modules/Games/Services/ChatterbotService.cs b/src/NadekoBot/Modules/Games/Services/ChatterbotService.cs index afa44664a..a940f629c 100644 --- a/src/NadekoBot/Modules/Games/Services/ChatterbotService.cs +++ b/src/NadekoBot/Modules/Games/Services/ChatterbotService.cs @@ -1,14 +1,8 @@ -using System.Collections.Concurrent; -using System.Threading.Tasks; -using Discord; -using Discord.WebSocket; -using NadekoBot.Common.ModuleBehaviors; +using NadekoBot.Common.ModuleBehaviors; using NadekoBot.Extensions; using NadekoBot.Modules.Permissions.Common; using NadekoBot.Modules.Permissions.Services; -using NadekoBot.Services; using NadekoBot.Modules.Games.Common.ChatterBot; -using System.Net.Http; namespace NadekoBot.Modules.Games.Services; diff --git a/src/NadekoBot/Modules/Games/Services/GamesConfigService.cs b/src/NadekoBot/Modules/Games/Services/GamesConfigService.cs index d3ae2df91..d8138e263 100644 --- a/src/NadekoBot/Modules/Games/Services/GamesConfigService.cs +++ b/src/NadekoBot/Modules/Games/Services/GamesConfigService.cs @@ -1,6 +1,4 @@ -using NadekoBot.Common; -using NadekoBot.Common.Configs; -using NadekoBot.Services; +using NadekoBot.Common.Configs; using NadekoBot.Modules.Games.Common; namespace NadekoBot.Modules.Games.Services; diff --git a/src/NadekoBot/Modules/Games/Services/GamesService.cs b/src/NadekoBot/Modules/Games/Services/GamesService.cs index f65a5276d..21504a0e4 100644 --- a/src/NadekoBot/Modules/Games/Services/GamesService.cs +++ b/src/NadekoBot/Modules/Games/Services/GamesService.cs @@ -1,17 +1,9 @@ -using Discord; -using NadekoBot.Common; -using NadekoBot.Services; -using NadekoBot.Extensions; +using NadekoBot.Extensions; using NadekoBot.Modules.Games.Common; using NadekoBot.Modules.Games.Common.Acrophobia; using NadekoBot.Modules.Games.Common.Nunchi; using NadekoBot.Modules.Games.Common.Trivia; using Newtonsoft.Json; -using System.Collections.Concurrent; -using System.IO; -using System.Net.Http; -using System.Threading; -using System.Threading.Tasks; using Microsoft.Extensions.Caching.Memory; namespace NadekoBot.Modules.Games.Services; diff --git a/src/NadekoBot/Modules/Games/Services/PollService.cs b/src/NadekoBot/Modules/Games/Services/PollService.cs index 7d05a8771..77a0efc6c 100644 --- a/src/NadekoBot/Modules/Games/Services/PollService.cs +++ b/src/NadekoBot/Modules/Games/Services/PollService.cs @@ -1,10 +1,6 @@ -using System.Collections.Concurrent; -using System.Threading.Tasks; -using Discord; -using NadekoBot.Common.ModuleBehaviors; +using NadekoBot.Common.ModuleBehaviors; using NadekoBot.Modules.Games.Common; using NadekoBot.Common.Collections; -using NadekoBot.Services; using NadekoBot.Services.Database.Models; using NadekoBot.Db; using NadekoBot.Extensions; diff --git a/src/NadekoBot/Modules/Games/SpeedTypingCommands.cs b/src/NadekoBot/Modules/Games/SpeedTypingCommands.cs index 36ad09f51..28bdfa450 100644 --- a/src/NadekoBot/Modules/Games/SpeedTypingCommands.cs +++ b/src/NadekoBot/Modules/Games/SpeedTypingCommands.cs @@ -1,12 +1,6 @@ -using Discord; -using Discord.Commands; -using Discord.WebSocket; -using NadekoBot.Extensions; -using System.Threading.Tasks; -using NadekoBot.Common.Attributes; +using NadekoBot.Extensions; using NadekoBot.Modules.Games.Common; using NadekoBot.Modules.Games.Services; -using NadekoBot.Common; namespace NadekoBot.Modules.Games; diff --git a/src/NadekoBot/Modules/Games/TicTacToeCommands.cs b/src/NadekoBot/Modules/Games/TicTacToeCommands.cs index 760f25a3a..6a07f12d4 100644 --- a/src/NadekoBot/Modules/Games/TicTacToeCommands.cs +++ b/src/NadekoBot/Modules/Games/TicTacToeCommands.cs @@ -1,12 +1,5 @@ -using Discord; -using Discord.Commands; -using Discord.WebSocket; -using NadekoBot.Common.Attributes; -using NadekoBot.Common; -using NadekoBot.Modules.Games.Common; +using NadekoBot.Modules.Games.Common; using NadekoBot.Modules.Games.Services; -using System.Threading; -using System.Threading.Tasks; namespace NadekoBot.Modules.Games; diff --git a/src/NadekoBot/Modules/Games/TriviaCommands.cs b/src/NadekoBot/Modules/Games/TriviaCommands.cs index 0faea70ac..6fd1953e2 100644 --- a/src/NadekoBot/Modules/Games/TriviaCommands.cs +++ b/src/NadekoBot/Modules/Games/TriviaCommands.cs @@ -1,12 +1,5 @@ -using Discord; -using Discord.Commands; -using Discord.WebSocket; -using NadekoBot.Services; -using System.Threading.Tasks; -using NadekoBot.Common.Attributes; -using NadekoBot.Modules.Games.Common.Trivia; +using NadekoBot.Modules.Games.Common.Trivia; using NadekoBot.Modules.Games.Services; -using NadekoBot.Common; namespace NadekoBot.Modules.Games; diff --git a/src/NadekoBot/Modules/Help/Common/CommandsOptions.cs b/src/NadekoBot/Modules/Help/Common/CommandsOptions.cs index 62abb2170..17f80d83e 100644 --- a/src/NadekoBot/Modules/Help/Common/CommandsOptions.cs +++ b/src/NadekoBot/Modules/Help/Common/CommandsOptions.cs @@ -1,5 +1,4 @@ using CommandLine; -using NadekoBot.Common; namespace NadekoBot.Modules.Help.Common; diff --git a/src/NadekoBot/Modules/Help/Help.cs b/src/NadekoBot/Modules/Help/Help.cs index a2f118c36..76eb4b729 100644 --- a/src/NadekoBot/Modules/Help/Help.cs +++ b/src/NadekoBot/Modules/Help/Help.cs @@ -1,21 +1,11 @@ -using Discord; -using Discord.Commands; -using NadekoBot.Common; -using NadekoBot.Common.Attributes; -using NadekoBot.Common.Replacements; using NadekoBot.Modules.Help.Common; -using NadekoBot.Services; using NadekoBot.Extensions; using NadekoBot.Modules.Help.Services; using NadekoBot.Modules.Permissions.Services; using Newtonsoft.Json; -using System.IO; using System.Text; using System.Text.Json; -using System.Threading.Tasks; using Amazon.S3; -using Amazon.S3.Model; -using Discord.WebSocket; namespace NadekoBot.Modules.Help; diff --git a/src/NadekoBot/Modules/Help/Services/HelpService.cs b/src/NadekoBot/Modules/Help/Services/HelpService.cs index 827f8adc1..15a75e90b 100644 --- a/src/NadekoBot/Modules/Help/Services/HelpService.cs +++ b/src/NadekoBot/Modules/Help/Services/HelpService.cs @@ -1,12 +1,6 @@ -using System.Threading.Tasks; -using Discord; -using Discord.Commands; -using NadekoBot.Extensions; -using NadekoBot.Common.Attributes; +using NadekoBot.Extensions; using NadekoBot.Common.ModuleBehaviors; -using NadekoBot.Services; using CommandLine; -using NadekoBot.Common.Replacements; using NadekoBot.Modules.Administration.Services; namespace NadekoBot.Modules.Help.Services; diff --git a/src/NadekoBot/Modules/Music/Common/IMusicPlayer.cs b/src/NadekoBot/Modules/Music/Common/IMusicPlayer.cs index 1fa2a07a1..f8b7343f9 100644 --- a/src/NadekoBot/Modules/Music/Common/IMusicPlayer.cs +++ b/src/NadekoBot/Modules/Music/Common/IMusicPlayer.cs @@ -1,5 +1,4 @@ -using System.Threading.Tasks; -using NadekoBot.Services.Database.Models; +using NadekoBot.Services.Database.Models; #nullable enable namespace NadekoBot.Modules.Music; diff --git a/src/NadekoBot/Modules/Music/Common/IPlatformQueryResolver.cs b/src/NadekoBot/Modules/Music/Common/IPlatformQueryResolver.cs index 1e7039438..861d8ab2e 100644 --- a/src/NadekoBot/Modules/Music/Common/IPlatformQueryResolver.cs +++ b/src/NadekoBot/Modules/Music/Common/IPlatformQueryResolver.cs @@ -1,6 +1,4 @@ #nullable enable -using System.Threading.Tasks; - namespace NadekoBot.Modules.Music; public interface IPlatformQueryResolver diff --git a/src/NadekoBot/Modules/Music/Common/ITrackCacher.cs b/src/NadekoBot/Modules/Music/Common/ITrackCacher.cs index d1f1e0702..37f9d4ebe 100644 --- a/src/NadekoBot/Modules/Music/Common/ITrackCacher.cs +++ b/src/NadekoBot/Modules/Music/Common/ITrackCacher.cs @@ -1,6 +1,4 @@ #nullable enable -using System.Threading.Tasks; - namespace NadekoBot.Modules.Music; public interface ITrackCacher diff --git a/src/NadekoBot/Modules/Music/Common/ITrackInfo.cs b/src/NadekoBot/Modules/Music/Common/ITrackInfo.cs index 6db9acbcc..80853b8c5 100644 --- a/src/NadekoBot/Modules/Music/Common/ITrackInfo.cs +++ b/src/NadekoBot/Modules/Music/Common/ITrackInfo.cs @@ -1,6 +1,4 @@ #nullable enable -using System.Threading.Tasks; - namespace NadekoBot.Modules.Music; public interface ITrackInfo diff --git a/src/NadekoBot/Modules/Music/Common/ITrackResolveProvider.cs b/src/NadekoBot/Modules/Music/Common/ITrackResolveProvider.cs index abb7b5ff3..9514eb3a2 100644 --- a/src/NadekoBot/Modules/Music/Common/ITrackResolveProvider.cs +++ b/src/NadekoBot/Modules/Music/Common/ITrackResolveProvider.cs @@ -1,6 +1,4 @@ #nullable enable -using System.Threading.Tasks; - namespace NadekoBot.Modules.Music; public interface ITrackResolveProvider diff --git a/src/NadekoBot/Modules/Music/Common/IVoiceProxy.cs b/src/NadekoBot/Modules/Music/Common/IVoiceProxy.cs index 34e327b6e..3f366b629 100644 --- a/src/NadekoBot/Modules/Music/Common/IVoiceProxy.cs +++ b/src/NadekoBot/Modules/Music/Common/IVoiceProxy.cs @@ -1,5 +1,4 @@ -using System.Threading.Tasks; -using Ayu.Discord.Voice; +using Ayu.Discord.Voice; namespace NadekoBot.Modules.Music; diff --git a/src/NadekoBot/Modules/Music/Common/IYoutubeResolver.cs b/src/NadekoBot/Modules/Music/Common/IYoutubeResolver.cs index 9f6622909..5efb2bfcc 100644 --- a/src/NadekoBot/Modules/Music/Common/IYoutubeResolver.cs +++ b/src/NadekoBot/Modules/Music/Common/IYoutubeResolver.cs @@ -1,6 +1,5 @@ #nullable enable using System.Text.RegularExpressions; -using System.Threading.Tasks; namespace NadekoBot.Modules.Music; diff --git a/src/NadekoBot/Modules/Music/Common/Impl/MusicExtensions.cs b/src/NadekoBot/Modules/Music/Common/Impl/MusicExtensions.cs index 5b48f4c4b..1cf417eb1 100644 --- a/src/NadekoBot/Modules/Music/Common/Impl/MusicExtensions.cs +++ b/src/NadekoBot/Modules/Music/Common/Impl/MusicExtensions.cs @@ -1,5 +1,4 @@ -using Discord; -using NadekoBot.Extensions; +using NadekoBot.Extensions; namespace NadekoBot.Modules.Music; diff --git a/src/NadekoBot/Modules/Music/Common/Impl/MusicPlayer.cs b/src/NadekoBot/Modules/Music/Common/Impl/MusicPlayer.cs index 464bf8536..afc2b35a9 100644 --- a/src/NadekoBot/Modules/Music/Common/Impl/MusicPlayer.cs +++ b/src/NadekoBot/Modules/Music/Common/Impl/MusicPlayer.cs @@ -3,10 +3,7 @@ using System.ComponentModel; using System.Diagnostics; using System.Runtime.CompilerServices; using System.Runtime.InteropServices; -using System.Threading; -using System.Threading.Tasks; using Ayu.Discord.Voice; -using NadekoBot.Common; using NadekoBot.Services.Database.Models; namespace NadekoBot.Modules.Music; diff --git a/src/NadekoBot/Modules/Music/Common/Impl/MusicQueue.cs b/src/NadekoBot/Modules/Music/Common/Impl/MusicQueue.cs index 8c1894d19..11e65d180 100644 --- a/src/NadekoBot/Modules/Music/Common/Impl/MusicQueue.cs +++ b/src/NadekoBot/Modules/Music/Common/Impl/MusicQueue.cs @@ -1,6 +1,4 @@ #nullable enable -using System.Threading.Tasks; - namespace NadekoBot.Modules.Music; public sealed partial class MusicQueue diff --git a/src/NadekoBot/Modules/Music/Common/Impl/RedisTrackCacher.cs b/src/NadekoBot/Modules/Music/Common/Impl/RedisTrackCacher.cs index fb39d2597..e06357c0d 100644 --- a/src/NadekoBot/Modules/Music/Common/Impl/RedisTrackCacher.cs +++ b/src/NadekoBot/Modules/Music/Common/Impl/RedisTrackCacher.cs @@ -1,7 +1,6 @@ #nullable enable using System.Runtime.CompilerServices; using System.Text.Json; -using System.Threading.Tasks; using StackExchange.Redis; namespace NadekoBot.Modules.Music; diff --git a/src/NadekoBot/Modules/Music/Common/Impl/RemoteTrackInfo.cs b/src/NadekoBot/Modules/Music/Common/Impl/RemoteTrackInfo.cs index aecd1a342..1a4cf53fe 100644 --- a/src/NadekoBot/Modules/Music/Common/Impl/RemoteTrackInfo.cs +++ b/src/NadekoBot/Modules/Music/Common/Impl/RemoteTrackInfo.cs @@ -1,6 +1,4 @@ #nullable enable -using System.Threading.Tasks; - namespace NadekoBot.Modules.Music; public sealed class RemoteTrackInfo : ITrackInfo diff --git a/src/NadekoBot/Modules/Music/Common/Impl/SimpleTrackInfo.cs b/src/NadekoBot/Modules/Music/Common/Impl/SimpleTrackInfo.cs index f5d4a013e..c9190d45d 100644 --- a/src/NadekoBot/Modules/Music/Common/Impl/SimpleTrackInfo.cs +++ b/src/NadekoBot/Modules/Music/Common/Impl/SimpleTrackInfo.cs @@ -1,6 +1,4 @@ #nullable enable -using System.Threading.Tasks; - namespace NadekoBot.Modules.Music; public sealed class SimpleTrackInfo : ITrackInfo diff --git a/src/NadekoBot/Modules/Music/Common/Impl/VoiceProxy.cs b/src/NadekoBot/Modules/Music/Common/Impl/VoiceProxy.cs index 3f00c494f..795e008ca 100644 --- a/src/NadekoBot/Modules/Music/Common/Impl/VoiceProxy.cs +++ b/src/NadekoBot/Modules/Music/Common/Impl/VoiceProxy.cs @@ -1,5 +1,4 @@ -using System.Threading.Tasks; -using Ayu.Discord.Voice; +using Ayu.Discord.Voice; using Ayu.Discord.Voice.Models; namespace NadekoBot.Modules.Music; diff --git a/src/NadekoBot/Modules/Music/Common/Resolvers/LocalTrackResolver.cs b/src/NadekoBot/Modules/Music/Common/Resolvers/LocalTrackResolver.cs index 1db4861d3..b38724c56 100644 --- a/src/NadekoBot/Modules/Music/Common/Resolvers/LocalTrackResolver.cs +++ b/src/NadekoBot/Modules/Music/Common/Resolvers/LocalTrackResolver.cs @@ -1,8 +1,6 @@ using System.ComponentModel; using System.Diagnostics; -using System.IO; using System.Text; -using System.Threading.Tasks; #nullable enable namespace NadekoBot.Modules.Music.Resolvers; diff --git a/src/NadekoBot/Modules/Music/Common/Resolvers/RadioResolveStrategy.cs b/src/NadekoBot/Modules/Music/Common/Resolvers/RadioResolveStrategy.cs index c2a616507..3f59935c1 100644 --- a/src/NadekoBot/Modules/Music/Common/Resolvers/RadioResolveStrategy.cs +++ b/src/NadekoBot/Modules/Music/Common/Resolvers/RadioResolveStrategy.cs @@ -1,6 +1,4 @@ -using System.Net.Http; -using System.Text.RegularExpressions; -using System.Threading.Tasks; +using System.Text.RegularExpressions; using NadekoBot.Extensions; namespace NadekoBot.Modules.Music.Resolvers; diff --git a/src/NadekoBot/Modules/Music/Common/Resolvers/SoundcloudResolver.cs b/src/NadekoBot/Modules/Music/Common/Resolvers/SoundcloudResolver.cs index ff3c57021..1af373f0f 100644 --- a/src/NadekoBot/Modules/Music/Common/Resolvers/SoundcloudResolver.cs +++ b/src/NadekoBot/Modules/Music/Common/Resolvers/SoundcloudResolver.cs @@ -1,7 +1,4 @@ -using System.Net.Http; -using System.Runtime.CompilerServices; -using System.Threading.Tasks; -using NadekoBot.Services; +using System.Runtime.CompilerServices; using Newtonsoft.Json.Linq; #nullable enable diff --git a/src/NadekoBot/Modules/Music/Common/Resolvers/TrackResolveProvider.cs b/src/NadekoBot/Modules/Music/Common/Resolvers/TrackResolveProvider.cs index a05430e40..630859f5e 100644 --- a/src/NadekoBot/Modules/Music/Common/Resolvers/TrackResolveProvider.cs +++ b/src/NadekoBot/Modules/Music/Common/Resolvers/TrackResolveProvider.cs @@ -1,6 +1,4 @@ #nullable enable -using System.Threading.Tasks; - namespace NadekoBot.Modules.Music; public sealed class TrackResolveProvider : ITrackResolveProvider diff --git a/src/NadekoBot/Modules/Music/Common/Resolvers/YtdlYoutubeResolver.cs b/src/NadekoBot/Modules/Music/Common/Resolvers/YtdlYoutubeResolver.cs index 9762f4cd7..4aaa4c2d0 100644 --- a/src/NadekoBot/Modules/Music/Common/Resolvers/YtdlYoutubeResolver.cs +++ b/src/NadekoBot/Modules/Music/Common/Resolvers/YtdlYoutubeResolver.cs @@ -1,8 +1,6 @@ #nullable enable using System.Globalization; using System.Text.RegularExpressions; -using System.Threading.Tasks; -using NadekoBot.Services; using NadekoBot.Extensions; namespace NadekoBot.Modules.Music; diff --git a/src/NadekoBot/Modules/Music/Music.cs b/src/NadekoBot/Modules/Music/Music.cs index 78bd058f2..7f380282a 100644 --- a/src/NadekoBot/Modules/Music/Music.cs +++ b/src/NadekoBot/Modules/Music/Music.cs @@ -1,10 +1,4 @@ -using System.Threading; -using System.Threading.Tasks; -using Discord; -using Discord.Commands; -using NadekoBot.Common; -using NadekoBot.Common.Attributes; -using NadekoBot.Services.Database.Models; +using NadekoBot.Services.Database.Models; using NadekoBot.Extensions; using NadekoBot.Modules.Administration.Services; using NadekoBot.Modules.Music.Services; diff --git a/src/NadekoBot/Modules/Music/PlaylistCommands.cs b/src/NadekoBot/Modules/Music/PlaylistCommands.cs index 40a29e64f..0e4a89d37 100644 --- a/src/NadekoBot/Modules/Music/PlaylistCommands.cs +++ b/src/NadekoBot/Modules/Music/PlaylistCommands.cs @@ -1,10 +1,4 @@ -using System.Threading; -using System.Threading.Tasks; -using Discord; -using Discord.Commands; -using NadekoBot.Common.Attributes; -using NadekoBot.Services; -using NadekoBot.Services.Database.Models; +using NadekoBot.Services.Database.Models; using NadekoBot.Db; using NadekoBot.Extensions; using NadekoBot.Modules.Music.Services; diff --git a/src/NadekoBot/Modules/Music/Services/AyuVoiceStateService.cs b/src/NadekoBot/Modules/Music/Services/AyuVoiceStateService.cs index 6e473c42c..aaa64f090 100644 --- a/src/NadekoBot/Modules/Music/Services/AyuVoiceStateService.cs +++ b/src/NadekoBot/Modules/Music/Services/AyuVoiceStateService.cs @@ -1,10 +1,5 @@ -using System.Collections.Concurrent; -using System.Reflection; -using System.Threading; -using System.Threading.Tasks; +using System.Reflection; using Ayu.Discord.Voice; -using Discord.WebSocket; -using NadekoBot.Services; namespace NadekoBot.Modules.Music.Services; diff --git a/src/NadekoBot/Modules/Music/Services/IMusicService.cs b/src/NadekoBot/Modules/Music/Services/IMusicService.cs index fe8eabc64..624137078 100644 --- a/src/NadekoBot/Modules/Music/Services/IMusicService.cs +++ b/src/NadekoBot/Modules/Music/Services/IMusicService.cs @@ -1,8 +1,5 @@ #nullable enable using System.Diagnostics.CodeAnalysis; -using System.Threading.Tasks; -using Discord; -using NadekoBot.Common; using NadekoBot.Services.Database.Models; namespace NadekoBot.Modules.Music.Services; diff --git a/src/NadekoBot/Modules/Music/Services/MusicService.cs b/src/NadekoBot/Modules/Music/Services/MusicService.cs index b20181bec..742a1fea7 100644 --- a/src/NadekoBot/Modules/Music/Services/MusicService.cs +++ b/src/NadekoBot/Modules/Music/Services/MusicService.cs @@ -1,10 +1,5 @@ #nullable enable -using System.Collections.Concurrent; using System.Diagnostics.CodeAnalysis; -using System.Threading.Tasks; -using Discord; -using Discord.WebSocket; -using NadekoBot.Services; using NadekoBot.Services.Database.Models; using NadekoBot.Db; using NadekoBot.Extensions; diff --git a/src/NadekoBot/Modules/Music/Services/extractor/YtLoader.cs b/src/NadekoBot/Modules/Music/Services/extractor/YtLoader.cs index 57e14b33d..bc72f51d6 100644 --- a/src/NadekoBot/Modules/Music/Services/extractor/YtLoader.cs +++ b/src/NadekoBot/Modules/Music/Services/extractor/YtLoader.cs @@ -1,8 +1,6 @@ using System.Globalization; -using System.Net.Http; using System.Text; using System.Text.Json; -using System.Threading.Tasks; namespace NadekoBot.Modules.Music.Services; diff --git a/src/NadekoBot/Modules/Nsfw/Common/Downloaders/DanbooruImageDownloader.cs b/src/NadekoBot/Modules/Nsfw/Common/Downloaders/DanbooruImageDownloader.cs index 55256bcd0..35db6808f 100644 --- a/src/NadekoBot/Modules/Nsfw/Common/Downloaders/DanbooruImageDownloader.cs +++ b/src/NadekoBot/Modules/Nsfw/Common/Downloaders/DanbooruImageDownloader.cs @@ -1,8 +1,4 @@ -using System.Collections.Concurrent; -using System.Net.Http; -using System.Net.Http.Json; -using System.Threading; -using System.Threading.Tasks; +using System.Net.Http.Json; namespace NadekoBot.Modules.Nsfw.Common; diff --git a/src/NadekoBot/Modules/Nsfw/Common/Downloaders/DapiImageDownloader.cs b/src/NadekoBot/Modules/Nsfw/Common/Downloaders/DapiImageDownloader.cs index 84653ada6..99f07451c 100644 --- a/src/NadekoBot/Modules/Nsfw/Common/Downloaders/DapiImageDownloader.cs +++ b/src/NadekoBot/Modules/Nsfw/Common/Downloaders/DapiImageDownloader.cs @@ -1,7 +1,4 @@ -using System.Net.Http; -using System.Net.Http.Json; -using System.Threading; -using System.Threading.Tasks; +using System.Net.Http.Json; namespace NadekoBot.Modules.Nsfw.Common; diff --git a/src/NadekoBot/Modules/Nsfw/Common/Downloaders/DerpibooruImageDownloader.cs b/src/NadekoBot/Modules/Nsfw/Common/Downloaders/DerpibooruImageDownloader.cs index 0911182e6..43f2a476a 100644 --- a/src/NadekoBot/Modules/Nsfw/Common/Downloaders/DerpibooruImageDownloader.cs +++ b/src/NadekoBot/Modules/Nsfw/Common/Downloaders/DerpibooruImageDownloader.cs @@ -1,7 +1,4 @@ -using System.Net.Http; -using System.Net.Http.Json; -using System.Threading; -using System.Threading.Tasks; +using System.Net.Http.Json; using NadekoBot.Extensions; namespace NadekoBot.Modules.Nsfw.Common; diff --git a/src/NadekoBot/Modules/Nsfw/Common/Downloaders/E621ImageDownloader.cs b/src/NadekoBot/Modules/Nsfw/Common/Downloaders/E621ImageDownloader.cs index 084858bb3..f92c40ef1 100644 --- a/src/NadekoBot/Modules/Nsfw/Common/Downloaders/E621ImageDownloader.cs +++ b/src/NadekoBot/Modules/Nsfw/Common/Downloaders/E621ImageDownloader.cs @@ -1,7 +1,4 @@ -using System.Net.Http; -using System.Net.Http.Json; -using System.Threading; -using System.Threading.Tasks; +using System.Net.Http.Json; using NadekoBot.Extensions; namespace NadekoBot.Modules.Nsfw.Common; diff --git a/src/NadekoBot/Modules/Nsfw/Common/Downloaders/GelbooruImageDownloader.cs b/src/NadekoBot/Modules/Nsfw/Common/Downloaders/GelbooruImageDownloader.cs index 47babca14..3ae8a0b23 100644 --- a/src/NadekoBot/Modules/Nsfw/Common/Downloaders/GelbooruImageDownloader.cs +++ b/src/NadekoBot/Modules/Nsfw/Common/Downloaders/GelbooruImageDownloader.cs @@ -1,7 +1,4 @@ -using System.Net.Http; -using System.Text.Json; -using System.Threading; -using System.Threading.Tasks; +using System.Text.Json; namespace NadekoBot.Modules.Nsfw.Common; diff --git a/src/NadekoBot/Modules/Nsfw/Common/Downloaders/IImageDownloader.cs b/src/NadekoBot/Modules/Nsfw/Common/Downloaders/IImageDownloader.cs index 354c5c46f..cbc2d26a5 100644 --- a/src/NadekoBot/Modules/Nsfw/Common/Downloaders/IImageDownloader.cs +++ b/src/NadekoBot/Modules/Nsfw/Common/Downloaders/IImageDownloader.cs @@ -1,7 +1,4 @@ -using System.Threading; -using System.Threading.Tasks; - -namespace NadekoBot.Modules.Nsfw.Common; +namespace NadekoBot.Modules.Nsfw.Common; public interface IImageDownloader { diff --git a/src/NadekoBot/Modules/Nsfw/Common/Downloaders/ImageDownloader.cs b/src/NadekoBot/Modules/Nsfw/Common/Downloaders/ImageDownloader.cs index cc2a79695..e83a7f359 100644 --- a/src/NadekoBot/Modules/Nsfw/Common/Downloaders/ImageDownloader.cs +++ b/src/NadekoBot/Modules/Nsfw/Common/Downloaders/ImageDownloader.cs @@ -1,8 +1,5 @@ -using System.Net.Http; -using System.Text.Json; +using System.Text.Json; using System.Text.Json.Serialization; -using System.Threading; -using System.Threading.Tasks; namespace NadekoBot.Modules.Nsfw.Common; diff --git a/src/NadekoBot/Modules/Nsfw/Common/Downloaders/KonachanImageDownloader.cs b/src/NadekoBot/Modules/Nsfw/Common/Downloaders/KonachanImageDownloader.cs index b226b4f86..ef54ea35a 100644 --- a/src/NadekoBot/Modules/Nsfw/Common/Downloaders/KonachanImageDownloader.cs +++ b/src/NadekoBot/Modules/Nsfw/Common/Downloaders/KonachanImageDownloader.cs @@ -1,7 +1,4 @@ -using System.Net.Http; -using System.Net.Http.Json; -using System.Threading; -using System.Threading.Tasks; +using System.Net.Http.Json; namespace NadekoBot.Modules.Nsfw.Common; diff --git a/src/NadekoBot/Modules/Nsfw/Common/Downloaders/Rule34ImageDownloader.cs b/src/NadekoBot/Modules/Nsfw/Common/Downloaders/Rule34ImageDownloader.cs index 2d00aeaf3..c5910784a 100644 --- a/src/NadekoBot/Modules/Nsfw/Common/Downloaders/Rule34ImageDownloader.cs +++ b/src/NadekoBot/Modules/Nsfw/Common/Downloaders/Rule34ImageDownloader.cs @@ -1,7 +1,4 @@ -using System.Net.Http; -using System.Net.Http.Json; -using System.Threading; -using System.Threading.Tasks; +using System.Net.Http.Json; namespace NadekoBot.Modules.Nsfw.Common; diff --git a/src/NadekoBot/Modules/Nsfw/Common/Downloaders/SafebooruImageDownloader.cs b/src/NadekoBot/Modules/Nsfw/Common/Downloaders/SafebooruImageDownloader.cs index a43203306..f216e3719 100644 --- a/src/NadekoBot/Modules/Nsfw/Common/Downloaders/SafebooruImageDownloader.cs +++ b/src/NadekoBot/Modules/Nsfw/Common/Downloaders/SafebooruImageDownloader.cs @@ -1,7 +1,4 @@ -using System.Net.Http; -using System.Net.Http.Json; -using System.Threading; -using System.Threading.Tasks; +using System.Net.Http.Json; namespace NadekoBot.Modules.Nsfw.Common; diff --git a/src/NadekoBot/Modules/Nsfw/Common/Downloaders/SankakuImageDownloader.cs b/src/NadekoBot/Modules/Nsfw/Common/Downloaders/SankakuImageDownloader.cs index 94be3f2f5..4b5df3aa4 100644 --- a/src/NadekoBot/Modules/Nsfw/Common/Downloaders/SankakuImageDownloader.cs +++ b/src/NadekoBot/Modules/Nsfw/Common/Downloaders/SankakuImageDownloader.cs @@ -1,7 +1,4 @@ -using System.Net.Http; using System.Text.Json; -using System.Threading; -using System.Threading.Tasks; using NadekoBot.Extensions; namespace NadekoBot.Modules.Nsfw.Common; diff --git a/src/NadekoBot/Modules/Nsfw/Common/Downloaders/YandereImageDownloader.cs b/src/NadekoBot/Modules/Nsfw/Common/Downloaders/YandereImageDownloader.cs index ad2122f16..ec610a24a 100644 --- a/src/NadekoBot/Modules/Nsfw/Common/Downloaders/YandereImageDownloader.cs +++ b/src/NadekoBot/Modules/Nsfw/Common/Downloaders/YandereImageDownloader.cs @@ -1,7 +1,4 @@ -using System.Net.Http; -using System.Net.Http.Json; -using System.Threading; -using System.Threading.Tasks; +using System.Net.Http.Json; namespace NadekoBot.Modules.Nsfw.Common; diff --git a/src/NadekoBot/Modules/Nsfw/ISearchImagesService.cs b/src/NadekoBot/Modules/Nsfw/ISearchImagesService.cs index 904b66bc6..302adb305 100644 --- a/src/NadekoBot/Modules/Nsfw/ISearchImagesService.cs +++ b/src/NadekoBot/Modules/Nsfw/ISearchImagesService.cs @@ -1,7 +1,4 @@ -using System.Collections.Concurrent; -using System.Threading; -using System.Threading.Tasks; -using NadekoBot.Modules.Searches.Common; +using NadekoBot.Modules.Searches.Common; namespace NadekoBot.Modules.Nsfw; diff --git a/src/NadekoBot/Modules/Nsfw/Nsfw.cs b/src/NadekoBot/Modules/Nsfw/Nsfw.cs index d65d3624e..ca2f43511 100644 --- a/src/NadekoBot/Modules/Nsfw/Nsfw.cs +++ b/src/NadekoBot/Modules/Nsfw/Nsfw.cs @@ -1,14 +1,7 @@ -using Discord; -using Discord.Commands; -using NadekoBot.Common; -using NadekoBot.Common.Attributes; -using NadekoBot.Common.Collections; +using NadekoBot.Common.Collections; using NadekoBot.Extensions; using NadekoBot.Modules.Searches.Common; using Newtonsoft.Json.Linq; -using System.Net.Http; -using System.Threading; -using System.Threading.Tasks; namespace NadekoBot.Modules.Nsfw; diff --git a/src/NadekoBot/Modules/Nsfw/SearchImageCacher.cs b/src/NadekoBot/Modules/Nsfw/SearchImageCacher.cs index 3b4777158..ba86fbe15 100644 --- a/src/NadekoBot/Modules/Nsfw/SearchImageCacher.cs +++ b/src/NadekoBot/Modules/Nsfw/SearchImageCacher.cs @@ -1,11 +1,5 @@ -using System.Collections.Concurrent; -using System.Net.Http; -using System.Threading; -using System.Threading.Tasks; -using Microsoft.Extensions.Caching.Memory; -using NadekoBot.Common; +using Microsoft.Extensions.Caching.Memory; using NadekoBot.Extensions; -using NadekoBot.Services; namespace NadekoBot.Modules.Nsfw.Common; diff --git a/src/NadekoBot/Modules/Nsfw/SearchImagesService.cs b/src/NadekoBot/Modules/Nsfw/SearchImagesService.cs index 55a3f797a..03f165ec1 100644 --- a/src/NadekoBot/Modules/Nsfw/SearchImagesService.cs +++ b/src/NadekoBot/Modules/Nsfw/SearchImagesService.cs @@ -1,14 +1,7 @@ using Newtonsoft.Json.Linq; -using System.Collections.Concurrent; -using System.Net.Http; -using System.Threading.Tasks; -using System.Threading; using LinqToDB; -using NadekoBot.Common; using NadekoBot.Extensions; using NadekoBot.Modules.Searches.Common; -using NadekoBot.Services; -using NadekoBot.Services.Database.Models; using Newtonsoft.Json; using Booru = NadekoBot.Modules.Nsfw.Common.Booru; using SearchImageCacher = NadekoBot.Modules.Nsfw.Common.SearchImageCacher; diff --git a/src/NadekoBot/Modules/Permissions/BlacklistCommands.cs b/src/NadekoBot/Modules/Permissions/BlacklistCommands.cs index e0464d993..f36941361 100644 --- a/src/NadekoBot/Modules/Permissions/BlacklistCommands.cs +++ b/src/NadekoBot/Modules/Permissions/BlacklistCommands.cs @@ -1,11 +1,6 @@ -using Discord; -using Discord.Commands; -using NadekoBot.Common.Attributes; -using NadekoBot.Common.TypeReaders; +using NadekoBot.Common.TypeReaders; using NadekoBot.Services.Database.Models; using NadekoBot.Modules.Permissions.Services; -using System.Threading.Tasks; -using Discord.WebSocket; using NadekoBot.Extensions; namespace NadekoBot.Modules.Permissions; diff --git a/src/NadekoBot/Modules/Permissions/CmdCdsCommands.cs b/src/NadekoBot/Modules/Permissions/CmdCdsCommands.cs index 55cbfd763..b62473ea3 100644 --- a/src/NadekoBot/Modules/Permissions/CmdCdsCommands.cs +++ b/src/NadekoBot/Modules/Permissions/CmdCdsCommands.cs @@ -1,12 +1,6 @@ -using Discord; -using Discord.Commands; -using Microsoft.EntityFrameworkCore; +using Microsoft.EntityFrameworkCore; using NadekoBot.Extensions; -using NadekoBot.Services; using NadekoBot.Services.Database.Models; -using System.Collections.Concurrent; -using System.Threading.Tasks; -using NadekoBot.Common.Attributes; using NadekoBot.Common.Collections; using NadekoBot.Common.TypeReaders; using NadekoBot.Db; diff --git a/src/NadekoBot/Modules/Permissions/Common/PermissionExtensions.cs b/src/NadekoBot/Modules/Permissions/Common/PermissionExtensions.cs index c7e516ae2..b49466853 100644 --- a/src/NadekoBot/Modules/Permissions/Common/PermissionExtensions.cs +++ b/src/NadekoBot/Modules/Permissions/Common/PermissionExtensions.cs @@ -1,6 +1,4 @@ -using Discord; -using Discord.WebSocket; -using NadekoBot.Services.Database.Models; +using NadekoBot.Services.Database.Models; namespace NadekoBot.Modules.Permissions.Common; diff --git a/src/NadekoBot/Modules/Permissions/FilterCommands.cs b/src/NadekoBot/Modules/Permissions/FilterCommands.cs index 2e4a42d72..b1f58b80e 100644 --- a/src/NadekoBot/Modules/Permissions/FilterCommands.cs +++ b/src/NadekoBot/Modules/Permissions/FilterCommands.cs @@ -1,10 +1,5 @@ -using Discord; -using Discord.Commands; -using Microsoft.EntityFrameworkCore; +using Microsoft.EntityFrameworkCore; using NadekoBot.Extensions; -using NadekoBot.Services; -using System.Threading.Tasks; -using NadekoBot.Common.Attributes; using NadekoBot.Common.Collections; using NadekoBot.Modules.Permissions.Services; using NadekoBot.Services.Database.Models; diff --git a/src/NadekoBot/Modules/Permissions/GlobalPermissionCommands.cs b/src/NadekoBot/Modules/Permissions/GlobalPermissionCommands.cs index 18c8b4ea2..01bf4ee84 100644 --- a/src/NadekoBot/Modules/Permissions/GlobalPermissionCommands.cs +++ b/src/NadekoBot/Modules/Permissions/GlobalPermissionCommands.cs @@ -1,11 +1,6 @@ -using Discord; -using Discord.Commands; -using NadekoBot.Common.Attributes; -using NadekoBot.Common.TypeReaders; -using NadekoBot.Services; +using NadekoBot.Common.TypeReaders; using NadekoBot.Extensions; using NadekoBot.Modules.Permissions.Services; -using System.Threading.Tasks; namespace NadekoBot.Modules.Permissions; diff --git a/src/NadekoBot/Modules/Permissions/Permissions.cs b/src/NadekoBot/Modules/Permissions/Permissions.cs index 1cf3a4665..4e4ccc008 100644 --- a/src/NadekoBot/Modules/Permissions/Permissions.cs +++ b/src/NadekoBot/Modules/Permissions/Permissions.cs @@ -1,10 +1,4 @@ -using System.Threading.Tasks; -using Discord.Commands; -using NadekoBot.Services; -using Discord; -using NadekoBot.Services.Database.Models; -using Discord.WebSocket; -using NadekoBot.Common.Attributes; +using NadekoBot.Services.Database.Models; using NadekoBot.Common.TypeReaders; using NadekoBot.Common.TypeReaders.Models; using NadekoBot.Db; diff --git a/src/NadekoBot/Modules/Permissions/ResetPermissionsCommands.cs b/src/NadekoBot/Modules/Permissions/ResetPermissionsCommands.cs index f58a5937c..297037491 100644 --- a/src/NadekoBot/Modules/Permissions/ResetPermissionsCommands.cs +++ b/src/NadekoBot/Modules/Permissions/ResetPermissionsCommands.cs @@ -1,8 +1,4 @@ -using Discord; -using Discord.Commands; -using System.Threading.Tasks; -using NadekoBot.Common.Attributes; -using NadekoBot.Modules.Permissions.Services; +using NadekoBot.Modules.Permissions.Services; namespace NadekoBot.Modules.Permissions; diff --git a/src/NadekoBot/Modules/Permissions/Services/BlacklistService.cs b/src/NadekoBot/Modules/Permissions/Services/BlacklistService.cs index 9256bb40b..15957ed73 100644 --- a/src/NadekoBot/Modules/Permissions/Services/BlacklistService.cs +++ b/src/NadekoBot/Modules/Permissions/Services/BlacklistService.cs @@ -1,10 +1,6 @@ -using Discord; -using NadekoBot.Common.ModuleBehaviors; -using NadekoBot.Services; +using NadekoBot.Common.ModuleBehaviors; using NadekoBot.Services.Database.Models; -using System.Threading.Tasks; using Microsoft.EntityFrameworkCore; -using NadekoBot.Common; using NadekoBot.Db; namespace NadekoBot.Modules.Permissions.Services; diff --git a/src/NadekoBot/Modules/Permissions/Services/CmdCdService.cs b/src/NadekoBot/Modules/Permissions/Services/CmdCdService.cs index c7b452221..c2ed4f49d 100644 --- a/src/NadekoBot/Modules/Permissions/Services/CmdCdService.cs +++ b/src/NadekoBot/Modules/Permissions/Services/CmdCdService.cs @@ -1,10 +1,5 @@ -using System.Collections.Concurrent; -using System.Threading.Tasks; -using Discord; -using Discord.Commands; -using NadekoBot.Common.Collections; +using NadekoBot.Common.Collections; using NadekoBot.Common.ModuleBehaviors; -using NadekoBot.Services; using NadekoBot.Services.Database.Models; namespace NadekoBot.Modules.Permissions.Services; diff --git a/src/NadekoBot/Modules/Permissions/Services/FilterService.cs b/src/NadekoBot/Modules/Permissions/Services/FilterService.cs index 1d3403fb7..b16cb9f95 100644 --- a/src/NadekoBot/Modules/Permissions/Services/FilterService.cs +++ b/src/NadekoBot/Modules/Permissions/Services/FilterService.cs @@ -1,12 +1,6 @@ -using System.Collections.Concurrent; -using System.Threading.Tasks; -using Discord; -using Discord.Net; -using Discord.WebSocket; -using NadekoBot.Common.Collections; +using NadekoBot.Common.Collections; using NadekoBot.Common.ModuleBehaviors; using NadekoBot.Extensions; -using NadekoBot.Services; using Microsoft.EntityFrameworkCore; using NadekoBot.Services.Database.Models; using NadekoBot.Db; diff --git a/src/NadekoBot/Modules/Permissions/Services/GlobalPermissionService.cs b/src/NadekoBot/Modules/Permissions/Services/GlobalPermissionService.cs index 9ca8d4353..c2a113c36 100644 --- a/src/NadekoBot/Modules/Permissions/Services/GlobalPermissionService.cs +++ b/src/NadekoBot/Modules/Permissions/Services/GlobalPermissionService.cs @@ -1,7 +1,4 @@ -using System.Threading.Tasks; -using Discord.Commands; -using NadekoBot.Common.ModuleBehaviors; -using NadekoBot.Services; +using NadekoBot.Common.ModuleBehaviors; namespace NadekoBot.Modules.Permissions.Services; diff --git a/src/NadekoBot/Modules/Permissions/Services/PermissionsService.cs b/src/NadekoBot/Modules/Permissions/Services/PermissionsService.cs index faee98ccc..7c9295fbb 100644 --- a/src/NadekoBot/Modules/Permissions/Services/PermissionsService.cs +++ b/src/NadekoBot/Modules/Permissions/Services/PermissionsService.cs @@ -1,13 +1,7 @@ -using System.Collections.Concurrent; -using System.Threading.Tasks; -using Discord; -using Discord.Commands; -using Discord.WebSocket; -using Microsoft.EntityFrameworkCore; +using Microsoft.EntityFrameworkCore; using NadekoBot.Common.ModuleBehaviors; using NadekoBot.Extensions; using NadekoBot.Modules.Permissions.Common; -using NadekoBot.Services; using NadekoBot.Services.Database.Models; using NadekoBot.Db; diff --git a/src/NadekoBot/Modules/Searches/AnimeSearchCommands.cs b/src/NadekoBot/Modules/Searches/AnimeSearchCommands.cs index a7d0ec932..a9455443a 100644 --- a/src/NadekoBot/Modules/Searches/AnimeSearchCommands.cs +++ b/src/NadekoBot/Modules/Searches/AnimeSearchCommands.cs @@ -1,10 +1,6 @@ using AngleSharp; -using Discord; -using Discord.Commands; using NadekoBot.Extensions; using NadekoBot.Modules.Searches.Services; -using System.Threading.Tasks; -using NadekoBot.Common.Attributes; using AngleSharp.Html.Dom; namespace NadekoBot.Modules.Searches; diff --git a/src/NadekoBot/Modules/Searches/Common/StreamNotifications/NotifChecker.cs b/src/NadekoBot/Modules/Searches/Common/StreamNotifications/NotifChecker.cs index e44bd83cc..2f6e38200 100644 --- a/src/NadekoBot/Modules/Searches/Common/StreamNotifications/NotifChecker.cs +++ b/src/NadekoBot/Modules/Searches/Common/StreamNotifications/NotifChecker.cs @@ -1,6 +1,4 @@ -using System.Net.Http; -using System.Threading.Tasks; -using NadekoBot.Modules.Searches.Common.StreamNotifications.Providers; +using NadekoBot.Modules.Searches.Common.StreamNotifications.Providers; using NadekoBot.Db.Models; using Newtonsoft.Json; using StackExchange.Redis; diff --git a/src/NadekoBot/Modules/Searches/Common/StreamNotifications/Providers/PicartoProvider.cs b/src/NadekoBot/Modules/Searches/Common/StreamNotifications/Providers/PicartoProvider.cs index 882db7229..bb9bb2898 100644 --- a/src/NadekoBot/Modules/Searches/Common/StreamNotifications/Providers/PicartoProvider.cs +++ b/src/NadekoBot/Modules/Searches/Common/StreamNotifications/Providers/PicartoProvider.cs @@ -1,7 +1,4 @@ -using System.Net.Http; -using System.Net.Http.Headers; -using System.Text.RegularExpressions; -using System.Threading.Tasks; +using System.Text.RegularExpressions; using NadekoBot.Db.Models; using Newtonsoft.Json; diff --git a/src/NadekoBot/Modules/Searches/Common/StreamNotifications/Providers/Provider.cs b/src/NadekoBot/Modules/Searches/Common/StreamNotifications/Providers/Provider.cs index 6db91f80a..c0ac16e4a 100644 --- a/src/NadekoBot/Modules/Searches/Common/StreamNotifications/Providers/Provider.cs +++ b/src/NadekoBot/Modules/Searches/Common/StreamNotifications/Providers/Provider.cs @@ -1,6 +1,4 @@ -using System.Collections.Concurrent; -using System.Threading.Tasks; -using NadekoBot.Db.Models; +using NadekoBot.Db.Models; #nullable enable namespace NadekoBot.Modules.Searches.Common.StreamNotifications.Providers; diff --git a/src/NadekoBot/Modules/Searches/Common/StreamNotifications/Providers/TwitchProvider.cs b/src/NadekoBot/Modules/Searches/Common/StreamNotifications/Providers/TwitchProvider.cs index 593dd75b7..7a2ad2f03 100644 --- a/src/NadekoBot/Modules/Searches/Common/StreamNotifications/Providers/TwitchProvider.cs +++ b/src/NadekoBot/Modules/Searches/Common/StreamNotifications/Providers/TwitchProvider.cs @@ -1,6 +1,4 @@ -using System.Net.Http; -using System.Text.RegularExpressions; -using System.Threading.Tasks; +using System.Text.RegularExpressions; using NadekoBot.Db.Models; using Newtonsoft.Json; diff --git a/src/NadekoBot/Modules/Searches/CryptoCommands.cs b/src/NadekoBot/Modules/Searches/CryptoCommands.cs index bedbcf9c8..863619b33 100644 --- a/src/NadekoBot/Modules/Searches/CryptoCommands.cs +++ b/src/NadekoBot/Modules/Searches/CryptoCommands.cs @@ -1,8 +1,5 @@ -using Discord; -using NadekoBot.Common.Attributes; -using NadekoBot.Modules.Searches.Services; +using NadekoBot.Modules.Searches.Services; using NadekoBot.Extensions; -using System.Threading.Tasks; namespace NadekoBot.Modules.Searches; diff --git a/src/NadekoBot/Modules/Searches/FeedCommands.cs b/src/NadekoBot/Modules/Searches/FeedCommands.cs index 706748c4a..32b793b1e 100644 --- a/src/NadekoBot/Modules/Searches/FeedCommands.cs +++ b/src/NadekoBot/Modules/Searches/FeedCommands.cs @@ -1,10 +1,6 @@ -using Discord; -using Discord.Commands; -using NadekoBot.Common.Attributes; -using NadekoBot.Extensions; +using NadekoBot.Extensions; using NadekoBot.Modules.Searches.Services; using System.Text.RegularExpressions; -using System.Threading.Tasks; namespace NadekoBot.Modules.Searches; diff --git a/src/NadekoBot/Modules/Searches/JokeCommands.cs b/src/NadekoBot/Modules/Searches/JokeCommands.cs index f522b8cae..2f1d654d8 100644 --- a/src/NadekoBot/Modules/Searches/JokeCommands.cs +++ b/src/NadekoBot/Modules/Searches/JokeCommands.cs @@ -1,8 +1,4 @@ -using Discord.Commands; -using NadekoBot.Modules.Searches.Services; -using System.Threading.Tasks; -using NadekoBot.Common; -using NadekoBot.Common.Attributes; +using NadekoBot.Modules.Searches.Services; namespace NadekoBot.Modules.Searches; diff --git a/src/NadekoBot/Modules/Searches/MemegenCommands.cs b/src/NadekoBot/Modules/Searches/MemegenCommands.cs index 1a0f59814..c9178b625 100644 --- a/src/NadekoBot/Modules/Searches/MemegenCommands.cs +++ b/src/NadekoBot/Modules/Searches/MemegenCommands.cs @@ -1,9 +1,5 @@ using System.Collections.Immutable; -using System.Net.Http; using System.Text; -using System.Threading.Tasks; -using Discord.Commands; -using NadekoBot.Common.Attributes; using NadekoBot.Extensions; using Newtonsoft.Json; diff --git a/src/NadekoBot/Modules/Searches/OsuCommands.cs b/src/NadekoBot/Modules/Searches/OsuCommands.cs index eb11ec9c6..c0daa7d3e 100644 --- a/src/NadekoBot/Modules/Searches/OsuCommands.cs +++ b/src/NadekoBot/Modules/Searches/OsuCommands.cs @@ -1,10 +1,4 @@ -using Discord; -using Discord.Commands; -using NadekoBot.Extensions; -using System.Net.Http; -using System.Threading.Tasks; -using NadekoBot.Common.Attributes; -using NadekoBot.Common; +using NadekoBot.Extensions; using NadekoBot.Modules.Searches.Common; using Newtonsoft.Json; diff --git a/src/NadekoBot/Modules/Searches/PathOfExileCommands.cs b/src/NadekoBot/Modules/Searches/PathOfExileCommands.cs index fed4de1bb..231aa5685 100644 --- a/src/NadekoBot/Modules/Searches/PathOfExileCommands.cs +++ b/src/NadekoBot/Modules/Searches/PathOfExileCommands.cs @@ -1,13 +1,9 @@ -using Discord.Commands; -using NadekoBot.Common.Attributes; -using NadekoBot.Modules.Searches.Common; +using NadekoBot.Modules.Searches.Common; using NadekoBot.Extensions; using NadekoBot.Modules.Searches.Services; using Newtonsoft.Json; using Newtonsoft.Json.Linq; -using System.Net.Http; using System.Text.RegularExpressions; -using System.Threading.Tasks; namespace NadekoBot.Modules.Searches; diff --git a/src/NadekoBot/Modules/Searches/PlaceCommands.cs b/src/NadekoBot/Modules/Searches/PlaceCommands.cs index 75e0f5501..2ab95b982 100644 --- a/src/NadekoBot/Modules/Searches/PlaceCommands.cs +++ b/src/NadekoBot/Modules/Searches/PlaceCommands.cs @@ -1,9 +1,4 @@ -using Discord.Commands; -using System.Threading.Tasks; -using NadekoBot.Common; -using NadekoBot.Common.Attributes; - -namespace NadekoBot.Modules.Searches; +namespace NadekoBot.Modules.Searches; public partial class Searches { diff --git a/src/NadekoBot/Modules/Searches/PokemonSearchCommands.cs b/src/NadekoBot/Modules/Searches/PokemonSearchCommands.cs index 44439d151..6f1cdeaf4 100644 --- a/src/NadekoBot/Modules/Searches/PokemonSearchCommands.cs +++ b/src/NadekoBot/Modules/Searches/PokemonSearchCommands.cs @@ -1,10 +1,6 @@ -using Discord.Commands; -using NadekoBot.Extensions; +using NadekoBot.Extensions; using NadekoBot.Modules.Searches.Services; -using System.Threading.Tasks; -using NadekoBot.Common.Attributes; using NadekoBot.Common.Pokemon; -using NadekoBot.Services; namespace NadekoBot.Modules.Searches; diff --git a/src/NadekoBot/Modules/Searches/Searches.cs b/src/NadekoBot/Modules/Searches/Searches.cs index f6254d752..e22063292 100644 --- a/src/NadekoBot/Modules/Searches/Searches.cs +++ b/src/NadekoBot/Modules/Searches/Searches.cs @@ -1,12 +1,7 @@ using AngleSharp; using AngleSharp.Html.Dom; -using Discord; -using Discord.Commands; using Microsoft.Extensions.Caching.Memory; -using NadekoBot.Common; -using NadekoBot.Common.Attributes; using NadekoBot.Modules.Searches.Common; -using NadekoBot.Services; using NadekoBot.Extensions; using NadekoBot.Modules.Searches.Services; using Newtonsoft.Json; @@ -15,11 +10,7 @@ using SixLabors.ImageSharp; using SixLabors.ImageSharp.Drawing.Processing; using SixLabors.ImageSharp.PixelFormats; using SixLabors.ImageSharp.Processing; -using System.Collections.Concurrent; -using System.Diagnostics.CodeAnalysis; using System.Net; -using System.Net.Http; -using System.Threading.Tasks; using NadekoBot.Modules.Administration.Services; using Configuration = AngleSharp.Configuration; diff --git a/src/NadekoBot/Modules/Searches/Services/AnimeSearchService.cs b/src/NadekoBot/Modules/Searches/Services/AnimeSearchService.cs index fe2d09e9a..bc4195442 100644 --- a/src/NadekoBot/Modules/Searches/Services/AnimeSearchService.cs +++ b/src/NadekoBot/Modules/Searches/Services/AnimeSearchService.cs @@ -1,10 +1,7 @@ using AngleSharp; using AngleSharp.Html.Dom; -using NadekoBot.Services; using NadekoBot.Modules.Searches.Common; using Newtonsoft.Json; -using System.Net.Http; -using System.Threading.Tasks; namespace NadekoBot.Modules.Searches.Services; diff --git a/src/NadekoBot/Modules/Searches/Services/AtlExtensions.cs b/src/NadekoBot/Modules/Searches/Services/AtlExtensions.cs index 763e6d86a..458bbd73f 100644 --- a/src/NadekoBot/Modules/Searches/Services/AtlExtensions.cs +++ b/src/NadekoBot/Modules/Searches/Services/AtlExtensions.cs @@ -1,5 +1,4 @@ -using System.Threading.Tasks; -using LinqToDB.EntityFrameworkCore; +using LinqToDB.EntityFrameworkCore; using Microsoft.EntityFrameworkCore; using NadekoBot.Services.Database.Models; diff --git a/src/NadekoBot/Modules/Searches/Services/CryptoService.cs b/src/NadekoBot/Modules/Searches/Services/CryptoService.cs index def89e976..0500692fb 100644 --- a/src/NadekoBot/Modules/Searches/Services/CryptoService.cs +++ b/src/NadekoBot/Modules/Searches/Services/CryptoService.cs @@ -1,10 +1,6 @@ using NadekoBot.Modules.Searches.Common; -using NadekoBot.Services; using NadekoBot.Extensions; using Newtonsoft.Json; -using System.Net.Http; -using System.Threading; -using System.Threading.Tasks; namespace NadekoBot.Modules.Searches.Services; diff --git a/src/NadekoBot/Modules/Searches/Services/FeedsService.cs b/src/NadekoBot/Modules/Searches/Services/FeedsService.cs index 9c65c8c5e..4d6036f06 100644 --- a/src/NadekoBot/Modules/Searches/Services/FeedsService.cs +++ b/src/NadekoBot/Modules/Searches/Services/FeedsService.cs @@ -1,12 +1,7 @@ using CodeHollow.FeedReader.Feeds; -using Discord; -using Discord.WebSocket; using Microsoft.EntityFrameworkCore; -using NadekoBot.Services; using NadekoBot.Services.Database.Models; using NadekoBot.Extensions; -using System.Collections.Concurrent; -using System.Threading.Tasks; using NadekoBot.Db; namespace NadekoBot.Modules.Searches.Services; diff --git a/src/NadekoBot/Modules/Searches/Services/ITranslateService.cs b/src/NadekoBot/Modules/Searches/Services/ITranslateService.cs index caff0dd57..acb9b974b 100644 --- a/src/NadekoBot/Modules/Searches/Services/ITranslateService.cs +++ b/src/NadekoBot/Modules/Searches/Services/ITranslateService.cs @@ -1,6 +1,4 @@ -using System.Threading.Tasks; - -namespace NadekoBot.Modules.Searches; +namespace NadekoBot.Modules.Searches; public interface ITranslateService { diff --git a/src/NadekoBot/Modules/Searches/Services/SearchesService.cs b/src/NadekoBot/Modules/Searches/Services/SearchesService.cs index 47ddb2891..b0dd3917d 100644 --- a/src/NadekoBot/Modules/Searches/Services/SearchesService.cs +++ b/src/NadekoBot/Modules/Searches/Services/SearchesService.cs @@ -1,6 +1,4 @@ -using NadekoBot.Common; -using NadekoBot.Modules.Searches.Common; -using NadekoBot.Services; +using NadekoBot.Modules.Searches.Common; using NadekoBot.Extensions; using Newtonsoft.Json; using Newtonsoft.Json.Linq; @@ -8,10 +6,7 @@ using SixLabors.ImageSharp; using SixLabors.ImageSharp.Drawing.Processing; using SixLabors.ImageSharp.PixelFormats; using SixLabors.ImageSharp.Processing; -using System.IO; using System.Net; -using System.Net.Http; -using System.Threading.Tasks; using AngleSharp.Html.Dom; using AngleSharp.Html.Parser; using HorizontalAlignment = SixLabors.Fonts.HorizontalAlignment; diff --git a/src/NadekoBot/Modules/Searches/Services/StreamNotificationService.cs b/src/NadekoBot/Modules/Searches/Services/StreamNotificationService.cs index 527d02bfa..29ade10a7 100644 --- a/src/NadekoBot/Modules/Searches/Services/StreamNotificationService.cs +++ b/src/NadekoBot/Modules/Searches/Services/StreamNotificationService.cs @@ -1,17 +1,10 @@ -using System.Net.Http; -using System.Threading; -using System.Threading.Tasks; using Microsoft.EntityFrameworkCore; -using NadekoBot.Common; using NadekoBot.Modules.Searches.Common; using NadekoBot.Modules.Searches.Common.StreamNotifications; -using NadekoBot.Services; using NadekoBot.Services.Database.Models; using NadekoBot.Extensions; using StackExchange.Redis; -using Discord.WebSocket; using NadekoBot.Common.Collections; -using NadekoBot.Common.Replacements; using NadekoBot.Db; using NadekoBot.Db.Models; diff --git a/src/NadekoBot/Modules/Searches/Services/TranslateService.cs b/src/NadekoBot/Modules/Searches/Services/TranslateService.cs index b6a0c9fa0..80ececa0b 100644 --- a/src/NadekoBot/Modules/Searches/Services/TranslateService.cs +++ b/src/NadekoBot/Modules/Searches/Services/TranslateService.cs @@ -1,14 +1,9 @@ -using System.Collections.Concurrent; -using System.Net; -using System.Threading.Tasks; -using Discord; -using Discord.Net; +using System.Net; using LinqToDB; using LinqToDB.EntityFrameworkCore; using Microsoft.EntityFrameworkCore; using NadekoBot.Common.ModuleBehaviors; using NadekoBot.Extensions; -using NadekoBot.Services; namespace NadekoBot.Modules.Searches; diff --git a/src/NadekoBot/Modules/Searches/StreamNotificationCommands.cs b/src/NadekoBot/Modules/Searches/StreamNotificationCommands.cs index bd8e093eb..1aadc6ce8 100644 --- a/src/NadekoBot/Modules/Searches/StreamNotificationCommands.cs +++ b/src/NadekoBot/Modules/Searches/StreamNotificationCommands.cs @@ -1,12 +1,6 @@ -using Discord.Commands; -using Discord; -using System.Threading.Tasks; -using NadekoBot.Services; -using Microsoft.EntityFrameworkCore; -using NadekoBot.Common.Attributes; +using Microsoft.EntityFrameworkCore; using NadekoBot.Extensions; using NadekoBot.Modules.Searches.Services; -using Discord.WebSocket; using NadekoBot.Db; using NadekoBot.Db.Models; diff --git a/src/NadekoBot/Modules/Searches/TranslatorCommands.cs b/src/NadekoBot/Modules/Searches/TranslatorCommands.cs index b1def4cef..a63909693 100644 --- a/src/NadekoBot/Modules/Searches/TranslatorCommands.cs +++ b/src/NadekoBot/Modules/Searches/TranslatorCommands.cs @@ -1,8 +1,4 @@ -using Discord; -using Discord.Commands; -using NadekoBot.Extensions; -using System.Threading.Tasks; -using NadekoBot.Common.Attributes; +using NadekoBot.Extensions; namespace NadekoBot.Modules.Searches; diff --git a/src/NadekoBot/Modules/Searches/XkcdCommands.cs b/src/NadekoBot/Modules/Searches/XkcdCommands.cs index 2c9e22d65..01f131428 100644 --- a/src/NadekoBot/Modules/Searches/XkcdCommands.cs +++ b/src/NadekoBot/Modules/Searches/XkcdCommands.cs @@ -1,10 +1,5 @@ -using Discord.Commands; -using NadekoBot.Extensions; +using NadekoBot.Extensions; using Newtonsoft.Json; -using System.Net.Http; -using System.Threading.Tasks; -using NadekoBot.Common; -using NadekoBot.Common.Attributes; namespace NadekoBot.Modules.Searches; diff --git a/src/NadekoBot/Modules/Utility/CalcCommands.cs b/src/NadekoBot/Modules/Utility/CalcCommands.cs index e3b4b01bc..46e7eccd7 100644 --- a/src/NadekoBot/Modules/Utility/CalcCommands.cs +++ b/src/NadekoBot/Modules/Utility/CalcCommands.cs @@ -1,7 +1,4 @@ -using Discord.Commands; -using System.Reflection; -using System.Threading.Tasks; -using NadekoBot.Common.Attributes; +using System.Reflection; namespace NadekoBot.Modules.Utility; diff --git a/src/NadekoBot/Modules/Utility/CommandMapCommands.cs b/src/NadekoBot/Modules/Utility/CommandMapCommands.cs index e01e6b14e..e77d45629 100644 --- a/src/NadekoBot/Modules/Utility/CommandMapCommands.cs +++ b/src/NadekoBot/Modules/Utility/CommandMapCommands.cs @@ -1,12 +1,5 @@ -using Discord; -using Discord.Commands; -using Discord.WebSocket; -using Microsoft.EntityFrameworkCore; +using Microsoft.EntityFrameworkCore; using NadekoBot.Extensions; -using System.Collections.Concurrent; -using System.Threading.Tasks; -using NadekoBot.Common.Attributes; -using NadekoBot.Services; using NadekoBot.Services.Database.Models; using NadekoBot.Db; using NadekoBot.Modules.Utility.Services; diff --git a/src/NadekoBot/Modules/Utility/ConfigCommands.cs b/src/NadekoBot/Modules/Utility/ConfigCommands.cs index 7adb4410b..68889b1e2 100644 --- a/src/NadekoBot/Modules/Utility/ConfigCommands.cs +++ b/src/NadekoBot/Modules/Utility/ConfigCommands.cs @@ -1,9 +1,4 @@ -using Discord; -using Discord.Commands; -using NadekoBot.Common.Attributes; -using NadekoBot.Extensions; -using System.Threading.Tasks; -using NadekoBot.Services; +using NadekoBot.Extensions; using NadekoBot.Modules.Administration.Services; namespace NadekoBot.Modules.Utility; diff --git a/src/NadekoBot/Modules/Utility/InfoCommands.cs b/src/NadekoBot/Modules/Utility/InfoCommands.cs index 2fa9eade7..3d0c3a47f 100644 --- a/src/NadekoBot/Modules/Utility/InfoCommands.cs +++ b/src/NadekoBot/Modules/Utility/InfoCommands.cs @@ -1,11 +1,5 @@ -using Discord; -using Discord.Commands; -using Discord.WebSocket; using NadekoBot.Extensions; -using NadekoBot.Services; using System.Text; -using System.Threading.Tasks; -using NadekoBot.Common.Attributes; namespace NadekoBot.Modules.Utility; diff --git a/src/NadekoBot/Modules/Utility/InviteCommands.cs b/src/NadekoBot/Modules/Utility/InviteCommands.cs index 07bead4c6..044b10011 100644 --- a/src/NadekoBot/Modules/Utility/InviteCommands.cs +++ b/src/NadekoBot/Modules/Utility/InviteCommands.cs @@ -1,10 +1,5 @@ -using Discord; -using Discord.Commands; -using NadekoBot.Common.Attributes; -using NadekoBot.Common; -using NadekoBot.Modules.Utility.Services; +using NadekoBot.Modules.Utility.Services; using NadekoBot.Extensions; -using System.Threading.Tasks; namespace NadekoBot.Modules.Utility; diff --git a/src/NadekoBot/Modules/Utility/PatreonCommands.cs b/src/NadekoBot/Modules/Utility/PatreonCommands.cs index d6e0b7b5a..c90f75da5 100644 --- a/src/NadekoBot/Modules/Utility/PatreonCommands.cs +++ b/src/NadekoBot/Modules/Utility/PatreonCommands.cs @@ -1,8 +1,4 @@ -using System.Threading.Tasks; -using Discord.Commands; -using NadekoBot.Extensions; -using Discord; -using NadekoBot.Common.Attributes; +using NadekoBot.Extensions; using NadekoBot.Modules.Utility.Services; namespace NadekoBot.Modules.Utility; diff --git a/src/NadekoBot/Modules/Utility/QuoteCommands.cs b/src/NadekoBot/Modules/Utility/QuoteCommands.cs index 74c5fd3db..a497d395e 100644 --- a/src/NadekoBot/Modules/Utility/QuoteCommands.cs +++ b/src/NadekoBot/Modules/Utility/QuoteCommands.cs @@ -1,13 +1,5 @@ -using Discord; -using Discord.Commands; -using NadekoBot.Common; -using NadekoBot.Common.Attributes; -using NadekoBot.Common.Replacements; using NadekoBot.Extensions; -using System.Net.Http; -using System.Threading.Tasks; using NadekoBot.Common.Yml; -using NadekoBot.Services; using NadekoBot.Services.Database.Models; using NadekoBot.Db; using YamlDotNet.Serialization; diff --git a/src/NadekoBot/Modules/Utility/RemindCommands.cs b/src/NadekoBot/Modules/Utility/RemindCommands.cs index 5e72511ad..edfdcbf81 100644 --- a/src/NadekoBot/Modules/Utility/RemindCommands.cs +++ b/src/NadekoBot/Modules/Utility/RemindCommands.cs @@ -1,9 +1,4 @@ -using System.Threading.Tasks; -using Discord; -using Discord.Commands; -using NadekoBot.Common.Attributes; -using NadekoBot.Services; -using NadekoBot.Services.Database.Models; +using NadekoBot.Services.Database.Models; using NadekoBot.Db; using NadekoBot.Extensions; using NadekoBot.Modules.Administration.Services; diff --git a/src/NadekoBot/Modules/Utility/RepeatCommands.cs b/src/NadekoBot/Modules/Utility/RepeatCommands.cs index 91ba23c0d..9f34354fe 100644 --- a/src/NadekoBot/Modules/Utility/RepeatCommands.cs +++ b/src/NadekoBot/Modules/Utility/RepeatCommands.cs @@ -1,11 +1,7 @@ #nullable enable -using Discord; -using Discord.Commands; -using NadekoBot.Common.Attributes; using NadekoBot.Common.TypeReaders; using NadekoBot.Extensions; using NadekoBot.Modules.Utility.Services; -using System.Threading.Tasks; using NadekoBot.Common.TypeReaders.Models; namespace NadekoBot.Modules.Utility; diff --git a/src/NadekoBot/Modules/Utility/Services/CommandMapService.cs b/src/NadekoBot/Modules/Utility/Services/CommandMapService.cs index 1b1d6bcb1..33779e9d6 100644 --- a/src/NadekoBot/Modules/Utility/Services/CommandMapService.cs +++ b/src/NadekoBot/Modules/Utility/Services/CommandMapService.cs @@ -1,11 +1,6 @@ -using System.Collections.Concurrent; -using System.Threading.Tasks; -using Discord; -using NadekoBot.Common.ModuleBehaviors; +using NadekoBot.Common.ModuleBehaviors; using NadekoBot.Extensions; -using Discord.WebSocket; using Microsoft.EntityFrameworkCore; -using NadekoBot.Services; using NadekoBot.Services.Database.Models; using NadekoBot.Db; diff --git a/src/NadekoBot/Modules/Utility/Services/ConverterService.cs b/src/NadekoBot/Modules/Utility/Services/ConverterService.cs index 1cd84edb5..8c1827f0f 100644 --- a/src/NadekoBot/Modules/Utility/Services/ConverterService.cs +++ b/src/NadekoBot/Modules/Utility/Services/ConverterService.cs @@ -1,12 +1,6 @@ -using Discord.WebSocket; -using NadekoBot.Services; -using NadekoBot.Extensions; +using NadekoBot.Extensions; using NadekoBot.Modules.Utility.Common; using Newtonsoft.Json; -using System.IO; -using System.Net.Http; -using System.Threading; -using System.Threading.Tasks; namespace NadekoBot.Modules.Utility.Services; diff --git a/src/NadekoBot/Modules/Utility/Services/InviteService.cs b/src/NadekoBot/Modules/Utility/Services/InviteService.cs index 3de71f0e2..f846e5664 100644 --- a/src/NadekoBot/Modules/Utility/Services/InviteService.cs +++ b/src/NadekoBot/Modules/Utility/Services/InviteService.cs @@ -1,6 +1,4 @@ using CommandLine; -using NadekoBot.Common; -using NadekoBot.Services; namespace NadekoBot.Modules.Utility.Services; diff --git a/src/NadekoBot/Modules/Utility/Services/PatreonRewardsService.cs b/src/NadekoBot/Modules/Utility/Services/PatreonRewardsService.cs index 4dc0a4de5..a59097c03 100644 --- a/src/NadekoBot/Modules/Utility/Services/PatreonRewardsService.cs +++ b/src/NadekoBot/Modules/Utility/Services/PatreonRewardsService.cs @@ -1,13 +1,7 @@ -using Discord.WebSocket; -using NadekoBot.Services; -using NadekoBot.Services.Database.Models; +using NadekoBot.Services.Database.Models; using NadekoBot.Modules.Utility.Common.Patreon; -using System.Net.Http; using System.Net.Http.Json; using System.Text.Json.Serialization; -using System.Threading; -using System.Threading.Tasks; -using Discord; using LinqToDB.EntityFrameworkCore; using NadekoBot.Modules.Gambling.Services; using NadekoBot.Extensions; diff --git a/src/NadekoBot/Modules/Utility/Services/RemindService.cs b/src/NadekoBot/Modules/Utility/Services/RemindService.cs index 1a0dfe280..b6265265d 100644 --- a/src/NadekoBot/Modules/Utility/Services/RemindService.cs +++ b/src/NadekoBot/Modules/Utility/Services/RemindService.cs @@ -1,10 +1,6 @@ using System.Text.RegularExpressions; -using Discord; -using Discord.WebSocket; using NadekoBot.Extensions; -using NadekoBot.Services; using NadekoBot.Services.Database.Models; -using System.Threading.Tasks; using Microsoft.EntityFrameworkCore; namespace NadekoBot.Modules.Utility.Services; diff --git a/src/NadekoBot/Modules/Utility/Services/RepeaterService.cs b/src/NadekoBot/Modules/Utility/Services/RepeaterService.cs index 1bb5686a7..c50f606b6 100644 --- a/src/NadekoBot/Modules/Utility/Services/RepeaterService.cs +++ b/src/NadekoBot/Modules/Utility/Services/RepeaterService.cs @@ -1,15 +1,10 @@ #nullable enable -using Discord.WebSocket; using Microsoft.EntityFrameworkCore; using NadekoBot.Extensions; -using System.Threading.Tasks; -using Discord; using LinqToDB; using LinqToDB.EntityFrameworkCore; using NadekoBot.Common.Collections; using NadekoBot.Common.ModuleBehaviors; -using NadekoBot.Common.Replacements; -using NadekoBot.Services; using NadekoBot.Services.Database.Models; namespace NadekoBot.Modules.Utility.Services; diff --git a/src/NadekoBot/Modules/Utility/Services/StreamRoleService.cs b/src/NadekoBot/Modules/Utility/Services/StreamRoleService.cs index f2001e957..813bad895 100644 --- a/src/NadekoBot/Modules/Utility/Services/StreamRoleService.cs +++ b/src/NadekoBot/Modules/Utility/Services/StreamRoleService.cs @@ -1,14 +1,8 @@ -using System.Collections.Concurrent; -using System.Threading.Tasks; -using Discord; -using Discord.WebSocket; -using NadekoBot.Extensions; -using NadekoBot.Services; +using NadekoBot.Extensions; using NadekoBot.Services.Database.Models; using NadekoBot.Common.TypeReaders; using NadekoBot.Modules.Utility.Common; using NadekoBot.Modules.Utility.Common.Exceptions; -using Discord.Net; using NadekoBot.Db; namespace NadekoBot.Modules.Utility.Services; diff --git a/src/NadekoBot/Modules/Utility/Services/VerboseErrorsService.cs b/src/NadekoBot/Modules/Utility/Services/VerboseErrorsService.cs index 9ae259d90..823b1f37a 100644 --- a/src/NadekoBot/Modules/Utility/Services/VerboseErrorsService.cs +++ b/src/NadekoBot/Modules/Utility/Services/VerboseErrorsService.cs @@ -1,10 +1,6 @@ -using System.Threading.Tasks; -using Discord; -using Discord.Commands; -using NadekoBot.Common.Collections; +using NadekoBot.Common.Collections; using NadekoBot.Extensions; using NadekoBot.Modules.Help.Services; -using NadekoBot.Services; using NadekoBot.Db; namespace NadekoBot.Modules.Utility.Services; diff --git a/src/NadekoBot/Modules/Utility/StreamRoleCommands.cs b/src/NadekoBot/Modules/Utility/StreamRoleCommands.cs index 6d89aa53e..254102fd2 100644 --- a/src/NadekoBot/Modules/Utility/StreamRoleCommands.cs +++ b/src/NadekoBot/Modules/Utility/StreamRoleCommands.cs @@ -1,8 +1,4 @@ -using Discord; -using Discord.Commands; -using System.Threading.Tasks; -using NadekoBot.Common.Attributes; -using NadekoBot.Modules.Utility.Services; +using NadekoBot.Modules.Utility.Services; using NadekoBot.Common.TypeReaders; using NadekoBot.Modules.Utility.Common; diff --git a/src/NadekoBot/Modules/Utility/UnitConversionCommands.cs b/src/NadekoBot/Modules/Utility/UnitConversionCommands.cs index 81ea4722a..5e75bc045 100644 --- a/src/NadekoBot/Modules/Utility/UnitConversionCommands.cs +++ b/src/NadekoBot/Modules/Utility/UnitConversionCommands.cs @@ -1,9 +1,5 @@ -using Discord; -using Discord.Commands; -using NadekoBot.Common.Attributes; -using NadekoBot.Extensions; +using NadekoBot.Extensions; using NadekoBot.Modules.Utility.Services; -using System.Threading.Tasks; namespace NadekoBot.Modules.Utility; diff --git a/src/NadekoBot/Modules/Utility/Utility.cs b/src/NadekoBot/Modules/Utility/Utility.cs index 02b8893fc..e8059749a 100644 --- a/src/NadekoBot/Modules/Utility/Utility.cs +++ b/src/NadekoBot/Modules/Utility/Utility.cs @@ -1,19 +1,9 @@ -using Discord; -using Discord.Commands; -using Discord.WebSocket; -using NadekoBot.Common; -using NadekoBot.Common.Attributes; using NadekoBot.Extensions; using Newtonsoft.Json; using System.Diagnostics; -using System.Net.Http; using System.Text; using System.Text.Json; using System.Text.Json.Serialization; -using System.Threading; -using System.Threading.Tasks; -using NadekoBot.Common.Replacements; -using NadekoBot.Services; using SystemTextJsonSamples; namespace NadekoBot.Modules.Utility; diff --git a/src/NadekoBot/Modules/Utility/VerboseErrorCommands.cs b/src/NadekoBot/Modules/Utility/VerboseErrorCommands.cs index c68abc303..25665cb21 100644 --- a/src/NadekoBot/Modules/Utility/VerboseErrorCommands.cs +++ b/src/NadekoBot/Modules/Utility/VerboseErrorCommands.cs @@ -1,8 +1,4 @@ -using Discord; -using Discord.Commands; -using NadekoBot.Common.Attributes; -using NadekoBot.Modules.Utility.Services; -using System.Threading.Tasks; +using NadekoBot.Modules.Utility.Services; namespace NadekoBot.Modules.Utility; diff --git a/src/NadekoBot/Modules/Xp/Club.cs b/src/NadekoBot/Modules/Xp/Club.cs index 0e088d943..abf8d9f34 100644 --- a/src/NadekoBot/Modules/Xp/Club.cs +++ b/src/NadekoBot/Modules/Xp/Club.cs @@ -1,10 +1,5 @@ -using Discord; -using Discord.Commands; -using NadekoBot.Common.Attributes; -using NadekoBot.Extensions; +using NadekoBot.Extensions; using NadekoBot.Modules.Xp.Services; -using System.Threading.Tasks; -using NadekoBot.Db.Models; namespace NadekoBot.Modules.Xp; diff --git a/src/NadekoBot/Modules/Xp/Common/XpConfig.cs b/src/NadekoBot/Modules/Xp/Common/XpConfig.cs index 3f5626bce..2effb74a1 100644 --- a/src/NadekoBot/Modules/Xp/Common/XpConfig.cs +++ b/src/NadekoBot/Modules/Xp/Common/XpConfig.cs @@ -1,5 +1,4 @@ using Cloneable; -using NadekoBot.Common; using NadekoBot.Common.Yml; namespace NadekoBot.Modules.Xp; diff --git a/src/NadekoBot/Modules/Xp/Common/XpTemplate.cs b/src/NadekoBot/Modules/Xp/Common/XpTemplate.cs index eaacc7634..6c73f6efd 100644 --- a/src/NadekoBot/Modules/Xp/Common/XpTemplate.cs +++ b/src/NadekoBot/Modules/Xp/Common/XpTemplate.cs @@ -1,5 +1,4 @@ using Newtonsoft.Json; -using SixLabors.ImageSharp; using SixLabors.ImageSharp.PixelFormats; namespace NadekoBot.Modules.Xp; @@ -285,7 +284,7 @@ public class XpRgba32Converter : JsonConverter { public override Rgba32 ReadJson(JsonReader reader, Type objectType, Rgba32 existingValue, bool hasExistingValue, JsonSerializer serializer) { - return Color.ParseHex(reader.Value.ToString()); + return SixLabors.ImageSharp.Color.ParseHex(reader.Value?.ToString()); } public override void WriteJson(JsonWriter writer, Rgba32 value, JsonSerializer serializer) diff --git a/src/NadekoBot/Modules/Xp/ResetCommands.cs b/src/NadekoBot/Modules/Xp/ResetCommands.cs index 6064f7059..223576fb7 100644 --- a/src/NadekoBot/Modules/Xp/ResetCommands.cs +++ b/src/NadekoBot/Modules/Xp/ResetCommands.cs @@ -1,8 +1,4 @@ -using Discord; -using Discord.Commands; -using NadekoBot.Common.Attributes; -using NadekoBot.Modules.Xp.Services; -using System.Threading.Tasks; +using NadekoBot.Modules.Xp.Services; namespace NadekoBot.Modules.Xp; diff --git a/src/NadekoBot/Modules/Xp/Services/ClubService.cs b/src/NadekoBot/Modules/Xp/Services/ClubService.cs index ed7781f29..cbe96e5df 100644 --- a/src/NadekoBot/Modules/Xp/Services/ClubService.cs +++ b/src/NadekoBot/Modules/Xp/Services/ClubService.cs @@ -1,9 +1,5 @@ using NadekoBot.Db.Models; -using Discord; using NadekoBot.Extensions; -using System.Net.Http; -using System.Threading.Tasks; -using NadekoBot.Services; using NadekoBot.Db; namespace NadekoBot.Modules.Xp.Services; diff --git a/src/NadekoBot/Modules/Xp/Services/UserCacheItem.cs b/src/NadekoBot/Modules/Xp/Services/UserCacheItem.cs index 48f694095..a43ba21e6 100644 --- a/src/NadekoBot/Modules/Xp/Services/UserCacheItem.cs +++ b/src/NadekoBot/Modules/Xp/Services/UserCacheItem.cs @@ -1,6 +1,4 @@ -using Discord; - -namespace NadekoBot.Modules.Xp.Services; +namespace NadekoBot.Modules.Xp.Services; public class UserCacheItem { diff --git a/src/NadekoBot/Modules/Xp/Services/XpConfigService.cs b/src/NadekoBot/Modules/Xp/Services/XpConfigService.cs index 244b7dbf8..889318f5e 100644 --- a/src/NadekoBot/Modules/Xp/Services/XpConfigService.cs +++ b/src/NadekoBot/Modules/Xp/Services/XpConfigService.cs @@ -1,6 +1,4 @@ -using NadekoBot.Common; -using NadekoBot.Common.Configs; -using NadekoBot.Services; +using NadekoBot.Common.Configs; namespace NadekoBot.Modules.Xp.Services; diff --git a/src/NadekoBot/Modules/Xp/Services/XpService.cs b/src/NadekoBot/Modules/Xp/Services/XpService.cs index ed7af492c..44c0b1c98 100644 --- a/src/NadekoBot/Modules/Xp/Services/XpService.cs +++ b/src/NadekoBot/Modules/Xp/Services/XpService.cs @@ -1,6 +1,3 @@ -using Discord; -using Discord.WebSocket; -using NadekoBot.Common; using NadekoBot.Common.Collections; using NadekoBot.Db.Models; using NadekoBot.Extensions; @@ -11,12 +8,7 @@ using SixLabors.ImageSharp.Drawing.Processing; using SixLabors.ImageSharp.Formats; using SixLabors.ImageSharp.PixelFormats; using SixLabors.ImageSharp.Processing; -using System.Collections.Concurrent; -using System.IO; -using System.Net.Http; -using System.Threading.Tasks; using Microsoft.EntityFrameworkCore; -using NadekoBot.Services; using NadekoBot.Services.Database.Models; using NadekoBot.Db; using StackExchange.Redis; diff --git a/src/NadekoBot/Modules/Xp/Xp.cs b/src/NadekoBot/Modules/Xp/Xp.cs index cd6fd0017..bc176d14c 100644 --- a/src/NadekoBot/Modules/Xp/Xp.cs +++ b/src/NadekoBot/Modules/Xp/Xp.cs @@ -1,12 +1,6 @@ -using Discord; -using Discord.Commands; -using Discord.WebSocket; -using NadekoBot.Common.Attributes; -using NadekoBot.Common; -using NadekoBot.Services.Database.Models; +using NadekoBot.Services.Database.Models; using NadekoBot.Extensions; using NadekoBot.Modules.Xp.Services; -using System.Threading.Tasks; using NadekoBot.Modules.Gambling.Services; namespace NadekoBot.Modules.Xp; diff --git a/src/NadekoBot/Program.cs b/src/NadekoBot/Program.cs index a28847fd7..ce30b676e 100644 --- a/src/NadekoBot/Program.cs +++ b/src/NadekoBot/Program.cs @@ -1,12 +1,4 @@ -global using System; -global using Serilog; -global using System.Collections.Generic; -global using System.Linq; - -using NadekoBot; -using NadekoBot.Services; - -var pid = System.Environment.ProcessId; +var pid = Environment.ProcessId; var shardId = 0; int? totalShards = null; // 0 to read from creds.yml diff --git a/src/NadekoBot/Services/CommandHandler.cs b/src/NadekoBot/Services/CommandHandler.cs index 6206be014..0c36d241f 100644 --- a/src/NadekoBot/Services/CommandHandler.cs +++ b/src/NadekoBot/Services/CommandHandler.cs @@ -1,13 +1,6 @@ -using Discord; -using Discord.Commands; -using Discord.Net; -using Discord.WebSocket; -using NadekoBot.Common.Collections; +using NadekoBot.Common.Collections; using NadekoBot.Extensions; -using System.Collections.Concurrent; using System.Collections.Immutable; -using System.Threading; -using System.Threading.Tasks; using NadekoBot.Common.Configs; using NadekoBot.Db; diff --git a/src/NadekoBot/Services/DbService.cs b/src/NadekoBot/Services/DbService.cs index 5906a843c..d92c62eff 100644 --- a/src/NadekoBot/Services/DbService.cs +++ b/src/NadekoBot/Services/DbService.cs @@ -1,7 +1,6 @@ using Microsoft.Data.Sqlite; using Microsoft.EntityFrameworkCore; using NadekoBot.Services.Database; -using System.IO; using LinqToDB.EntityFrameworkCore; namespace NadekoBot.Services; diff --git a/src/NadekoBot/Services/GreetSettingsService.cs b/src/NadekoBot/Services/GreetSettingsService.cs index 7769576f2..7a60a5ae0 100644 --- a/src/NadekoBot/Services/GreetSettingsService.cs +++ b/src/NadekoBot/Services/GreetSettingsService.cs @@ -1,10 +1,5 @@ -using Discord; -using Discord.WebSocket; -using NadekoBot.Common.Replacements; -using NadekoBot.Services.Database.Models; +using NadekoBot.Services.Database.Models; using NadekoBot.Extensions; -using System.Collections.Concurrent; -using System.Threading.Tasks; using NadekoBot.Db; namespace NadekoBot.Services; diff --git a/src/NadekoBot/Services/IBehaviourExecutor.cs b/src/NadekoBot/Services/IBehaviourExecutor.cs index 6e3d407e1..5d9ea8c0c 100644 --- a/src/NadekoBot/Services/IBehaviourExecutor.cs +++ b/src/NadekoBot/Services/IBehaviourExecutor.cs @@ -1,9 +1,4 @@ -using System.Threading.Tasks; -using Discord; -using Discord.Commands; -using Discord.WebSocket; - -namespace NadekoBot.Services; +namespace NadekoBot.Services; public interface IBehaviourExecutor { diff --git a/src/NadekoBot/Services/ICoordinator.cs b/src/NadekoBot/Services/ICoordinator.cs index e374bd6a0..fda1acc13 100644 --- a/src/NadekoBot/Services/ICoordinator.cs +++ b/src/NadekoBot/Services/ICoordinator.cs @@ -1,6 +1,4 @@ -using System.Threading.Tasks; - -namespace NadekoBot.Services; +namespace NadekoBot.Services; public interface ICoordinator { diff --git a/src/NadekoBot/Services/ICurrencyService.cs b/src/NadekoBot/Services/ICurrencyService.cs index cda3f5e11..1e12f85c1 100644 --- a/src/NadekoBot/Services/ICurrencyService.cs +++ b/src/NadekoBot/Services/ICurrencyService.cs @@ -1,7 +1,4 @@ -using Discord; -using System.Threading.Tasks; - -namespace NadekoBot.Services; +namespace NadekoBot.Services; public interface ICurrencyService { diff --git a/src/NadekoBot/Services/IDataCache.cs b/src/NadekoBot/Services/IDataCache.cs index dd18f8d0e..d3006772c 100644 --- a/src/NadekoBot/Services/IDataCache.cs +++ b/src/NadekoBot/Services/IDataCache.cs @@ -1,5 +1,4 @@ using StackExchange.Redis; -using System.Threading.Tasks; namespace NadekoBot.Services; diff --git a/src/NadekoBot/Services/IEmbedBuilderService.cs b/src/NadekoBot/Services/IEmbedBuilderService.cs index 601474897..355ae8aaa 100644 --- a/src/NadekoBot/Services/IEmbedBuilderService.cs +++ b/src/NadekoBot/Services/IEmbedBuilderService.cs @@ -1,6 +1,4 @@ -using Discord; -using Discord.Commands; -using NadekoBot.Common.Configs; +using NadekoBot.Common.Configs; using NadekoBot.Extensions; namespace NadekoBot.Services; diff --git a/src/NadekoBot/Services/IGoogleApiService.cs b/src/NadekoBot/Services/IGoogleApiService.cs index 141372d51..52ae8b151 100644 --- a/src/NadekoBot/Services/IGoogleApiService.cs +++ b/src/NadekoBot/Services/IGoogleApiService.cs @@ -1,5 +1,4 @@ using Google.Apis.Customsearch.v1.Data; -using System.Threading.Tasks; namespace NadekoBot.Services; diff --git a/src/NadekoBot/Services/IImageCache.cs b/src/NadekoBot/Services/IImageCache.cs index a73cce9e8..0215e733c 100644 --- a/src/NadekoBot/Services/IImageCache.cs +++ b/src/NadekoBot/Services/IImageCache.cs @@ -1,7 +1,4 @@ -using NadekoBot.Common; -using System.Threading.Tasks; - -namespace NadekoBot.Services; +namespace NadekoBot.Services; public interface IImageCache { diff --git a/src/NadekoBot/Services/ILocalization.cs b/src/NadekoBot/Services/ILocalization.cs index c1ef2f441..16e831315 100644 --- a/src/NadekoBot/Services/ILocalization.cs +++ b/src/NadekoBot/Services/ILocalization.cs @@ -1,6 +1,4 @@ -using System.Collections.Concurrent; -using System.Globalization; -using Discord; +using System.Globalization; namespace NadekoBot.Services; diff --git a/src/NadekoBot/Services/Impl/BehaviorExecutor.cs b/src/NadekoBot/Services/Impl/BehaviorExecutor.cs index c6b21706d..3e362458f 100644 --- a/src/NadekoBot/Services/Impl/BehaviorExecutor.cs +++ b/src/NadekoBot/Services/Impl/BehaviorExecutor.cs @@ -1,8 +1,4 @@ -using System.Threading.Tasks; -using Discord; -using Discord.Commands; -using Discord.WebSocket; -using NadekoBot.Common.ModuleBehaviors; +using NadekoBot.Common.ModuleBehaviors; using NadekoBot.Extensions; using Microsoft.Extensions.DependencyInjection; diff --git a/src/NadekoBot/Services/Impl/BotCredsProvider.cs b/src/NadekoBot/Services/Impl/BotCredsProvider.cs index adfac1117..b66ff38d8 100644 --- a/src/NadekoBot/Services/Impl/BotCredsProvider.cs +++ b/src/NadekoBot/Services/Impl/BotCredsProvider.cs @@ -1,7 +1,5 @@ using Microsoft.Extensions.Configuration; -using System.IO; using Microsoft.Extensions.Primitives; -using NadekoBot.Common; using NadekoBot.Common.Yml; using Newtonsoft.Json; diff --git a/src/NadekoBot/Services/Impl/CurrencyService.cs b/src/NadekoBot/Services/Impl/CurrencyService.cs index f5435fcec..4c9ea8f38 100644 --- a/src/NadekoBot/Services/Impl/CurrencyService.cs +++ b/src/NadekoBot/Services/Impl/CurrencyService.cs @@ -1,9 +1,6 @@ -using Discord; -using Discord.WebSocket; -using NadekoBot.Services.Database; +using NadekoBot.Services.Database; using NadekoBot.Services.Database.Models; using NadekoBot.Extensions; -using System.Threading.Tasks; using NadekoBot.Db; using NadekoBot.Modules.Gambling.Services; diff --git a/src/NadekoBot/Services/Impl/FontProvider.cs b/src/NadekoBot/Services/Impl/FontProvider.cs index ddf3b5d1e..29d9523de 100644 --- a/src/NadekoBot/Services/Impl/FontProvider.cs +++ b/src/NadekoBot/Services/Impl/FontProvider.cs @@ -1,5 +1,4 @@ using SixLabors.Fonts; -using System.IO; namespace NadekoBot.Services; diff --git a/src/NadekoBot/Services/Impl/GoogleApiService.cs b/src/NadekoBot/Services/Impl/GoogleApiService.cs index 24e26601c..27814a1c3 100644 --- a/src/NadekoBot/Services/Impl/GoogleApiService.cs +++ b/src/NadekoBot/Services/Impl/GoogleApiService.cs @@ -2,15 +2,11 @@ using Google.Apis.Customsearch.v1; using Google.Apis.Services; using Google.Apis.Urlshortener.v1; -using Google.Apis.Urlshortener.v1.Data; using Google.Apis.YouTube.v3; -using NadekoBot.Common; using NadekoBot.Extensions; using Newtonsoft.Json.Linq; using System.Net; -using System.Net.Http; using System.Text.RegularExpressions; -using System.Threading.Tasks; namespace NadekoBot.Services; diff --git a/src/NadekoBot/Services/Impl/Localization.cs b/src/NadekoBot/Services/Impl/Localization.cs index 7c08b1d19..cf558b86e 100644 --- a/src/NadekoBot/Services/Impl/Localization.cs +++ b/src/NadekoBot/Services/Impl/Localization.cs @@ -1,9 +1,5 @@ -using System.Collections.Concurrent; -using System.Globalization; -using Discord; -using NadekoBot.Common; +using System.Globalization; using Newtonsoft.Json; -using System.IO; using NadekoBot.Db; namespace NadekoBot.Services; diff --git a/src/NadekoBot/Services/Impl/RedisCache.cs b/src/NadekoBot/Services/Impl/RedisCache.cs index 296f9420b..0c8d54d4b 100644 --- a/src/NadekoBot/Services/Impl/RedisCache.cs +++ b/src/NadekoBot/Services/Impl/RedisCache.cs @@ -2,7 +2,6 @@ using Newtonsoft.Json; using StackExchange.Redis; using System.Net; -using System.Threading.Tasks; namespace NadekoBot.Services; diff --git a/src/NadekoBot/Services/Impl/RedisImagesCache.cs b/src/NadekoBot/Services/Impl/RedisImagesCache.cs index 9719f2df5..5dde08ea6 100644 --- a/src/NadekoBot/Services/Impl/RedisImagesCache.cs +++ b/src/NadekoBot/Services/Impl/RedisImagesCache.cs @@ -1,10 +1,6 @@ -using NadekoBot.Common; -using NadekoBot.Extensions; +using NadekoBot.Extensions; using Newtonsoft.Json; using StackExchange.Redis; -using System.IO; -using System.Net.Http; -using System.Threading.Tasks; using NadekoBot.Common.ModuleBehaviors; using NadekoBot.Common.Yml; diff --git a/src/NadekoBot/Services/Impl/RedisLocalDataCache.cs b/src/NadekoBot/Services/Impl/RedisLocalDataCache.cs index c9a32fe36..01b79bd3d 100644 --- a/src/NadekoBot/Services/Impl/RedisLocalDataCache.cs +++ b/src/NadekoBot/Services/Impl/RedisLocalDataCache.cs @@ -3,8 +3,6 @@ using NadekoBot.Extensions; using NadekoBot.Modules.Games.Common.Trivia; using Newtonsoft.Json; using StackExchange.Redis; -using System.IO; -using Discord.WebSocket; namespace NadekoBot.Services; diff --git a/src/NadekoBot/Services/Impl/RemoteGrpcCoordinator.cs b/src/NadekoBot/Services/Impl/RemoteGrpcCoordinator.cs index aea4c04bf..32e2fce55 100644 --- a/src/NadekoBot/Services/Impl/RemoteGrpcCoordinator.cs +++ b/src/NadekoBot/Services/Impl/RemoteGrpcCoordinator.cs @@ -1,7 +1,4 @@ -using System.Threading.Tasks; -using Discord; -using Discord.WebSocket; -using Grpc.Core; +using Grpc.Core; using NadekoBot.Common.ModuleBehaviors; using NadekoBot.Coordinator; using NadekoBot.Extensions; diff --git a/src/NadekoBot/Services/Impl/SingleProcessCoordinator.cs b/src/NadekoBot/Services/Impl/SingleProcessCoordinator.cs index 196c7b1f6..4b7e3c878 100644 --- a/src/NadekoBot/Services/Impl/SingleProcessCoordinator.cs +++ b/src/NadekoBot/Services/Impl/SingleProcessCoordinator.cs @@ -1,6 +1,4 @@ using System.Diagnostics; -using System.Threading.Tasks; -using Discord.WebSocket; namespace NadekoBot.Services; diff --git a/src/NadekoBot/Services/Impl/SoundCloudApiService.cs b/src/NadekoBot/Services/Impl/SoundCloudApiService.cs index 37340f2b8..ca0fa4ff0 100644 --- a/src/NadekoBot/Services/Impl/SoundCloudApiService.cs +++ b/src/NadekoBot/Services/Impl/SoundCloudApiService.cs @@ -1,6 +1,4 @@ using Newtonsoft.Json; -using System.Net.Http; -using System.Threading.Tasks; namespace NadekoBot.Services; diff --git a/src/NadekoBot/Services/Impl/StartingGuildsListService.cs b/src/NadekoBot/Services/Impl/StartingGuildsListService.cs index 832df9350..da2cebd4c 100644 --- a/src/NadekoBot/Services/Impl/StartingGuildsListService.cs +++ b/src/NadekoBot/Services/Impl/StartingGuildsListService.cs @@ -1,5 +1,4 @@ -using Discord.WebSocket; -using System.Collections.Immutable; +using System.Collections.Immutable; using System.Collections; namespace NadekoBot.Services; diff --git a/src/NadekoBot/Services/Impl/StatsService.cs b/src/NadekoBot/Services/Impl/StatsService.cs index 493bcfd3a..5adf511aa 100644 --- a/src/NadekoBot/Services/Impl/StatsService.cs +++ b/src/NadekoBot/Services/Impl/StatsService.cs @@ -1,11 +1,6 @@ -using Discord; -using Discord.WebSocket; -using NadekoBot.Common.ModuleBehaviors; +using NadekoBot.Common.ModuleBehaviors; using NadekoBot.Extensions; using System.Diagnostics; -using System.Net.Http; -using System.Threading; -using System.Threading.Tasks; namespace NadekoBot.Services; diff --git a/src/NadekoBot/Services/Impl/YtdlOperation.cs b/src/NadekoBot/Services/Impl/YtdlOperation.cs index 70b86e03e..1b4eefe1b 100644 --- a/src/NadekoBot/Services/Impl/YtdlOperation.cs +++ b/src/NadekoBot/Services/Impl/YtdlOperation.cs @@ -1,7 +1,6 @@ using System.ComponentModel; using System.Diagnostics; using System.Text; -using System.Threading.Tasks; using NadekoBot.Extensions; namespace NadekoBot.Services; diff --git a/src/NadekoBot/Services/Settings/BotConfigService.cs b/src/NadekoBot/Services/Settings/BotConfigService.cs index fd3018a8a..d8e4e1c0b 100644 --- a/src/NadekoBot/Services/Settings/BotConfigService.cs +++ b/src/NadekoBot/Services/Settings/BotConfigService.cs @@ -1,5 +1,4 @@ -using NadekoBot.Common; -using NadekoBot.Common.Configs; +using NadekoBot.Common.Configs; using SixLabors.ImageSharp.PixelFormats; namespace NadekoBot.Services; diff --git a/src/NadekoBot/Services/Settings/ConfigServiceBase.cs b/src/NadekoBot/Services/Settings/ConfigServiceBase.cs index ee3de3588..e1943db06 100644 --- a/src/NadekoBot/Services/Settings/ConfigServiceBase.cs +++ b/src/NadekoBot/Services/Settings/ConfigServiceBase.cs @@ -1,9 +1,6 @@ -using System.IO; -using System.Linq.Expressions; +using System.Linq.Expressions; using System.Reflection; -using System.Threading.Tasks; using NadekoBot.Common.Yml; -using NadekoBot.Common; using NadekoBot.Common.Configs; namespace NadekoBot.Services; diff --git a/src/NadekoBot/Services/strings/impl/LocalFileStringsSource.cs b/src/NadekoBot/Services/strings/impl/LocalFileStringsSource.cs index f5379477f..5e3da2855 100644 --- a/src/NadekoBot/Services/strings/impl/LocalFileStringsSource.cs +++ b/src/NadekoBot/Services/strings/impl/LocalFileStringsSource.cs @@ -1,5 +1,4 @@ -using System.IO; -using Newtonsoft.Json; +using Newtonsoft.Json; using YamlDotNet.Serialization; namespace NadekoBot.Services; diff --git a/src/NadekoBot/Services/strings/impl/RedisBotStringsProvider.cs b/src/NadekoBot/Services/strings/impl/RedisBotStringsProvider.cs index 3dd2ccdf3..0ca073f65 100644 --- a/src/NadekoBot/Services/strings/impl/RedisBotStringsProvider.cs +++ b/src/NadekoBot/Services/strings/impl/RedisBotStringsProvider.cs @@ -1,5 +1,4 @@ using System.Web; -using Discord.WebSocket; using NadekoBot.Extensions; using StackExchange.Redis; diff --git a/src/NadekoBot/_Extensions/Extensions.cs b/src/NadekoBot/_Extensions/Extensions.cs index 88ad387ef..a9ccd178e 100644 --- a/src/NadekoBot/_Extensions/Extensions.cs +++ b/src/NadekoBot/_Extensions/Extensions.cs @@ -1,9 +1,4 @@ -using Discord; -using Discord.Commands; -using Discord.WebSocket; -using NadekoBot.Common; -using NadekoBot.Common.Collections; -using NadekoBot.Services; +using NadekoBot.Common.Collections; using NadekoBot.Modules.Administration.Services; using SixLabors.Fonts; using SixLabors.ImageSharp; @@ -14,14 +9,10 @@ using SixLabors.ImageSharp.Formats.Png; using SixLabors.ImageSharp.PixelFormats; using SixLabors.ImageSharp.Processing; using System.Globalization; -using System.IO; -using System.Net.Http; using System.Net.Http.Headers; using System.Text; using System.Text.Json; using System.Text.RegularExpressions; -using System.Threading.Tasks; -using NadekoBot.Common.Attributes; using Color = Discord.Color; using JsonSerializer = System.Text.Json.JsonSerializer; diff --git a/src/NadekoBot/_Extensions/IEnumerableExtensions.cs b/src/NadekoBot/_Extensions/IEnumerableExtensions.cs index 06bde1272..f7a37e0e8 100644 --- a/src/NadekoBot/_Extensions/IEnumerableExtensions.cs +++ b/src/NadekoBot/_Extensions/IEnumerableExtensions.cs @@ -1,6 +1,4 @@ -using System.Collections.Concurrent; -using System.Security.Cryptography; -using System.Threading.Tasks; +using System.Security.Cryptography; using NadekoBot.Common.Collections; using NadekoBot.Services.Database.Models; diff --git a/src/NadekoBot/_Extensions/IMessageChannelExtensions.cs b/src/NadekoBot/_Extensions/IMessageChannelExtensions.cs index 8d79ddc5b..fcebcce31 100644 --- a/src/NadekoBot/_Extensions/IMessageChannelExtensions.cs +++ b/src/NadekoBot/_Extensions/IMessageChannelExtensions.cs @@ -1,10 +1,4 @@ -using Discord; -using Discord.Commands; -using Discord.WebSocket; -using System.Threading.Tasks; -using NadekoBot.Services; - -namespace NadekoBot.Extensions; +namespace NadekoBot.Extensions; public static class IMessageChannelExtensions { diff --git a/src/NadekoBot/_Extensions/IUserExtensions.cs b/src/NadekoBot/_Extensions/IUserExtensions.cs index 1591940ca..55c45969f 100644 --- a/src/NadekoBot/_Extensions/IUserExtensions.cs +++ b/src/NadekoBot/_Extensions/IUserExtensions.cs @@ -1,8 +1,4 @@ -using Discord; -using System.IO; -using System.Threading.Tasks; -using NadekoBot.Db.Models; -using NadekoBot.Services; +using NadekoBot.Db.Models; namespace NadekoBot.Extensions; diff --git a/src/NadekoBot/_Extensions/MusicExtensions.cs b/src/NadekoBot/_Extensions/MusicExtensions.cs index 89de51ee1..ad7a69701 100644 --- a/src/NadekoBot/_Extensions/MusicExtensions.cs +++ b/src/NadekoBot/_Extensions/MusicExtensions.cs @@ -1,6 +1,4 @@ -using Discord; - -namespace NadekoBot.Extensions; +namespace NadekoBot.Extensions; public static class MusicExtensions { diff --git a/src/NadekoBot/_Extensions/ProcessExtensions.cs b/src/NadekoBot/_Extensions/ProcessExtensions.cs index 7f6533b58..059291ace 100644 --- a/src/NadekoBot/_Extensions/ProcessExtensions.cs +++ b/src/NadekoBot/_Extensions/ProcessExtensions.cs @@ -3,7 +3,6 @@ // https://github.com/aspnet/Common/blob/dev/shared/Microsoft.Extensions.Process.Sources/ProcessHelper.cs using System.Diagnostics; -using System.IO; using System.Runtime.InteropServices; namespace NadekoBot.Extensions; diff --git a/src/NadekoBot/_Extensions/StringExtensions.cs b/src/NadekoBot/_Extensions/StringExtensions.cs index 063e000a9..e98f0d96f 100644 --- a/src/NadekoBot/_Extensions/StringExtensions.cs +++ b/src/NadekoBot/_Extensions/StringExtensions.cs @@ -1,8 +1,6 @@ using Newtonsoft.Json; -using System.IO; using System.Text; using System.Text.RegularExpressions; -using System.Threading.Tasks; using NadekoBot.Common.Yml; namespace NadekoBot.Extensions;