mirror of
https://gitlab.com/Kwoth/nadekobot.git
synced 2025-09-11 09:48:26 -04:00
Massive cleanup
- Removed GuildConfigs repository, moved to extensions - Moved StreamSettings extension to GuildConfig extensions - namespace NadekoBot.Core has been simplified to NadekoBot in many places (more to come) - Replaced some raw delete queries with simple linqtodb queries
This commit is contained in:
@@ -1,9 +1,11 @@
|
||||
using Discord;
|
||||
using Discord.Commands;
|
||||
using NadekoBot.Core.Services;
|
||||
using NadekoBot.Services;
|
||||
using System;
|
||||
using System.Threading.Tasks;
|
||||
using NadekoBot.Common.Attributes;
|
||||
using NadekoBot.Core.Services;
|
||||
using NadekoBot.Modules.Administration;
|
||||
using NadekoBot.Modules.Games.Services;
|
||||
using NadekoBot.Modules.Games.Common.ChatterBot;
|
||||
|
||||
@@ -32,7 +34,7 @@ namespace NadekoBot.Modules.Games
|
||||
{
|
||||
using (var uow = _db.GetDbContext())
|
||||
{
|
||||
uow.GuildConfigs.SetCleverbotEnabled(ctx.Guild.Id, false);
|
||||
uow._context.GuildConfigs.SetCleverbotEnabled(ctx.Guild.Id, false);
|
||||
await uow.SaveChangesAsync();
|
||||
}
|
||||
await ReplyConfirmLocalizedAsync("cleverbot_disabled").ConfigureAwait(false);
|
||||
@@ -43,7 +45,7 @@ namespace NadekoBot.Modules.Games
|
||||
|
||||
using (var uow = _db.GetDbContext())
|
||||
{
|
||||
uow.GuildConfigs.SetCleverbotEnabled(ctx.Guild.Id, true);
|
||||
uow._context.GuildConfigs.SetCleverbotEnabled(ctx.Guild.Id, true);
|
||||
await uow.SaveChangesAsync();
|
||||
}
|
||||
|
||||
|
@@ -1,10 +1,12 @@
|
||||
using System.Threading.Tasks;
|
||||
using Discord;
|
||||
using NadekoBot.Core.Services.Database.Models;
|
||||
using NadekoBot.Core.Services;
|
||||
using NadekoBot.Services.Database.Models;
|
||||
using NadekoBot.Services;
|
||||
using System;
|
||||
using System.Linq;
|
||||
using System.Threading;
|
||||
using NadekoBot.Core.Services;
|
||||
using NadekoBot.Core.Services.Database.Models;
|
||||
|
||||
namespace NadekoBot.Modules.Games.Common
|
||||
{
|
||||
|
@@ -6,8 +6,10 @@ using System.Text;
|
||||
using System.Threading;
|
||||
using System.Threading.Tasks;
|
||||
using CommandLine;
|
||||
using NadekoBot.Common;
|
||||
using NadekoBot.Core.Common;
|
||||
using NadekoBot.Core.Services;
|
||||
using NadekoBot.Services;
|
||||
|
||||
namespace NadekoBot.Modules.Games.Common
|
||||
{
|
||||
|
@@ -10,7 +10,7 @@ using Discord.Net;
|
||||
using Discord.WebSocket;
|
||||
using NadekoBot.Extensions;
|
||||
using NadekoBot.Core.Services;
|
||||
using NadekoBot.Core.Modules.Games.Common.Trivia;
|
||||
using NadekoBot.Modules.Games.Common.Trivia;
|
||||
using NadekoBot.Modules.Games.Services;
|
||||
using Serilog;
|
||||
|
||||
|
@@ -1,7 +1,7 @@
|
||||
using CommandLine;
|
||||
using NadekoBot.Core.Common;
|
||||
|
||||
namespace NadekoBot.Core.Modules.Games.Common.Trivia
|
||||
namespace NadekoBot.Modules.Games.Common.Trivia
|
||||
{
|
||||
public class TriviaOptions : INadekoCommandOptions
|
||||
{
|
||||
|
@@ -7,8 +7,7 @@ using NadekoBot.Modules.Administration.Services;
|
||||
using NadekoBot.Modules.Gambling.Services;
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
using NadekoBot.Core.Modules.Gambling.Common;
|
||||
using NadekoBot.Core.Modules.Gambling.Services;
|
||||
using NadekoBot.Modules.Gambling.Common;
|
||||
|
||||
namespace NadekoBot.Modules.Games
|
||||
{
|
||||
|
@@ -6,9 +6,11 @@ using Discord;
|
||||
using Discord.WebSocket;
|
||||
using NadekoBot.Common.ModuleBehaviors;
|
||||
using NadekoBot.Modules.Games.Common;
|
||||
using NadekoBot.Services;
|
||||
using NadekoBot.Services.Database.Models;
|
||||
using NadekoBot.Common.Collections;
|
||||
using NadekoBot.Core.Services;
|
||||
using NadekoBot.Core.Services.Database.Models;
|
||||
using NadekoBot.Common.Collections;
|
||||
using NadekoBot.Extensions;
|
||||
using Serilog;
|
||||
|
||||
|
@@ -8,7 +8,6 @@ using NadekoBot.Common.Attributes;
|
||||
using NadekoBot.Modules.Games.Common.Trivia;
|
||||
using NadekoBot.Modules.Games.Services;
|
||||
using NadekoBot.Core.Common;
|
||||
using NadekoBot.Core.Modules.Games.Common.Trivia;
|
||||
|
||||
namespace NadekoBot.Modules.Games
|
||||
{
|
||||
|
Reference in New Issue
Block a user