Still want logging to console, only not Writing to database.
This commit is contained in:
parent
96c204e077
commit
bbf2789704
@ -41,9 +41,9 @@ namespace NadekoBot
|
|||||||
var commandService = NadekoBot.Client.GetService<CommandService>();
|
var commandService = NadekoBot.Client.GetService<CommandService>();
|
||||||
|
|
||||||
statsStopwatch.Start();
|
statsStopwatch.Start();
|
||||||
#if !NADEKO_RELEASE
|
|
||||||
commandService.CommandExecuted += StatsCollector_RanCommand;
|
commandService.CommandExecuted += StatsCollector_RanCommand;
|
||||||
#endif
|
|
||||||
Task.Run(StartCollecting);
|
Task.Run(StartCollecting);
|
||||||
|
|
||||||
commandLogTimer.Start();
|
commandLogTimer.Start();
|
||||||
@ -208,6 +208,7 @@ namespace NadekoBot
|
|||||||
private async void StatsCollector_RanCommand(object sender, CommandEventArgs e)
|
private async void StatsCollector_RanCommand(object sender, CommandEventArgs e)
|
||||||
{
|
{
|
||||||
Console.WriteLine($">> Cmd: {e.Command.Text}\nMsg: {e.Message.Text}\nUsr: {e.User.Name} [{e.User.Id}]\nSrvr: {e.Server?.Name ?? "PRIVATE"} [{e.Server?.Id}]\n-----");
|
Console.WriteLine($">> Cmd: {e.Command.Text}\nMsg: {e.Message.Text}\nUsr: {e.User.Name} [{e.User.Id}]\nSrvr: {e.Server?.Name ?? "PRIVATE"} [{e.Server?.Id}]\n-----");
|
||||||
|
#if !NADEKO_RELEASE
|
||||||
await Task.Run(() =>
|
await Task.Run(() =>
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
@ -231,6 +232,7 @@ namespace NadekoBot
|
|||||||
Console.WriteLine(ex);
|
Console.WriteLine(ex);
|
||||||
}
|
}
|
||||||
}).ConfigureAwait(false);
|
}).ConfigureAwait(false);
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
Loading…
Reference in New Issue
Block a user