Skip to content

Commit

Permalink
log testing
Browse files Browse the repository at this point in the history
  • Loading branch information
xiaoxiao921 committed Jun 18, 2020
1 parent 2903081 commit 8702675
Showing 1 changed file with 14 additions and 1 deletion.
15 changes: 14 additions & 1 deletion CHEF/Logger.cs
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,20 @@ internal static void Init(DiscordSocketClient client)
const long iDeathHdId = 125598628310941697;

_client = client;
_reportToUser = client.GetGuild(ror2ServerId)?.GetUser(iDeathHdId) ?? (IGuildUser) _client.Rest.GetGuildUserAsync(ror2ServerId, iDeathHdId).Result;
var guild = client.GetGuild(ror2ServerId);
if (guild == null)
{
Console.WriteLine("guild was null");
}
else
{
_reportToUser = guild.GetUser(iDeathHdId);
if (_reportToUser == null)
{
Console.WriteLine("_reportToUser was null");
_reportToUser = _client.Rest.GetGuildUserAsync(ror2ServerId, iDeathHdId).Result;
}
}
}

internal static void Log(string msg)
Expand Down

0 comments on commit 8702675

Please sign in to comment.