Fixed config not updating

This commit is contained in:
Kwoth
2016-08-25 01:41:11 +02:00
parent 4b080590b2
commit c09a851f74
10 changed files with 17 additions and 180 deletions

View File

@@ -43,7 +43,7 @@ namespace NadekoBot.Modules.Administration
public async Task Delmsgoncmd(IMessage imsg)
{
var channel = (ITextChannel)imsg.Channel;
Config conf;
GuildConfig conf;
using (var uow = DbHandler.UnitOfWork())
{
conf = uow.GuildConfigs.For(channel.Guild.Id);

View File

@@ -21,7 +21,7 @@ namespace NadekoBot.Modules.Administration
var _client = NadekoBot.Client;
_client.UserJoined += async (user) =>
{
Config conf;
GuildConfig conf;
using (var uow = DbHandler.UnitOfWork())
{
conf = uow.GuildConfigs.For(user.Guild.Id);
@@ -45,7 +45,7 @@ namespace NadekoBot.Modules.Administration
{
var channel = (ITextChannel)imsg.Channel;
Config conf;
GuildConfig conf;
using (var uow = DbHandler.UnitOfWork())
{
conf = uow.GuildConfigs.For(channel.Guild.Id);

View File

@@ -9,14 +9,14 @@
//// todo rewrite
//namespace NadekoBot.Modules.Administration
//{
// internal class ServerGreetCommand : DiscordCommand
// public partial class ServerGreetCommands
// {
// public static ConcurrentDictionary<ulong, AnnounceControls> AnnouncementsDictionary;
// public static long Greeted = 0;
// public ServerGreetCommand(DiscordModule module) : base(module)
// public ServerGreetCommands(DiscordModule module)
// {
// AnnouncementsDictionary = new ConcurrentDictionary<ulong, AnnounceControls>();
@@ -68,7 +68,7 @@
// catch { }
// }
// private async void UserJoined(object sender, Discord.UserEventArgs e)
// private async Task UserJoined(object sender, Discord.UserEventArgs e)
// {
// try
// {