v+t fixed
This commit is contained in:
parent
54f37219b8
commit
120be816a9
@ -128,9 +128,9 @@ namespace NadekoBot.Modules.Administration
|
|||||||
isEnabled = conf.VoicePlusTextEnabled = !conf.VoicePlusTextEnabled;
|
isEnabled = conf.VoicePlusTextEnabled = !conf.VoicePlusTextEnabled;
|
||||||
await uow.CompleteAsync().ConfigureAwait(false);
|
await uow.CompleteAsync().ConfigureAwait(false);
|
||||||
}
|
}
|
||||||
voicePlusTextCache.Add(guild.Id);
|
|
||||||
if (!isEnabled)
|
if (!isEnabled)
|
||||||
{
|
{
|
||||||
|
voicePlusTextCache.TryRemove(guild.Id);
|
||||||
foreach (var textChannel in guild.GetTextChannels().Where(c => c.Name.EndsWith("-voice")))
|
foreach (var textChannel in guild.GetTextChannels().Where(c => c.Name.EndsWith("-voice")))
|
||||||
{
|
{
|
||||||
try { await textChannel.DeleteAsync().ConfigureAwait(false); } catch { }
|
try { await textChannel.DeleteAsync().ConfigureAwait(false); } catch { }
|
||||||
@ -138,6 +138,7 @@ namespace NadekoBot.Modules.Administration
|
|||||||
await channel.SendMessageAsync("Successfuly removed voice + text feature.").ConfigureAwait(false);
|
await channel.SendMessageAsync("Successfuly removed voice + text feature.").ConfigureAwait(false);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
voicePlusTextCache.Add(guild.Id);
|
||||||
await channel.SendMessageAsync("Successfuly enabled voice + text feature.").ConfigureAwait(false);
|
await channel.SendMessageAsync("Successfuly enabled voice + text feature.").ConfigureAwait(false);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
15
src/NadekoBot/credentials_example.json
Normal file
15
src/NadekoBot/credentials_example.json
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
{
|
||||||
|
"ClientId": 123123123,
|
||||||
|
"BotId": null,
|
||||||
|
"Token": "",
|
||||||
|
"OwnerIds": [
|
||||||
|
0
|
||||||
|
],
|
||||||
|
"LoLApiKey": "",
|
||||||
|
"GoogleApiKey": "",
|
||||||
|
"MashapeKey": "",
|
||||||
|
"OsuApiKey": "",
|
||||||
|
"SoundCloudClientId": "",
|
||||||
|
"Db": null,
|
||||||
|
"TotalShards": 1
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user