mirror of
https://github.com/Impostor/Impostor.git
synced 2026-10-19 15:51:42 +00:00
Add scene param to forbidden scene log statement
I'm seeing multiple warnings in my server log about forbidden scene changes. Unfortunately this warning does not include the actual scene that was triggering the issue, which makes diagnosis/remediation difficult. Additionally change this logging call to use names suitable for structured logging.
This commit is contained in:
1 parent
35c66cda5f
commit
066eca09ee
1 file changed
+3
-2
@@ -245,9 +245,10 @@ namespace Impostor.Server.Net.State
|
||||
if (scene != "OnlineGame")
|
||||
{
|
||||
_logger.LogWarning(
|
||||
"Player {0} ({1}) tried to send SceneChangeFlag with disallowed scene.",
|
||||
"Player {PlayerName} ({ClientId}) tried to send SceneChangeFlag with disallowed scene \"{Scene}\".",
|
||||
sender.Client.Name,
|
||||
sender.Client.Id);
|
||||
sender.Client.Id,
|
||||
scene);
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user