From d8cbddf1f4adf5fce5399ea6674a7eeaa1b612a9 Mon Sep 17 00:00:00 2001 From: Pieter-Jan Briers Date: Sat, 6 Jan 2024 16:33:53 +0100 Subject: [PATCH] Fix bad sawmill IPostInjectInit (#23626) Same issue as https://github.com/space-wizards/RobustToolbox/commit/359811f71ee920220a86a570121173f731058748 --- Content.Server/Administration/BanPanelEui.cs | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/Content.Server/Administration/BanPanelEui.cs b/Content.Server/Administration/BanPanelEui.cs index eaea015d5d..aa6bd8d4bf 100644 --- a/Content.Server/Administration/BanPanelEui.cs +++ b/Content.Server/Administration/BanPanelEui.cs @@ -13,7 +13,7 @@ using Robust.Shared.Network; namespace Content.Server.Administration; -public sealed class BanPanelEui : BaseEui, IPostInjectInit +public sealed class BanPanelEui : BaseEui { [Dependency] private readonly IBanManager _banManager = default!; [Dependency] private readonly IEntityManager _entities = default!; @@ -23,7 +23,7 @@ public sealed class BanPanelEui : BaseEui, IPostInjectInit [Dependency] private readonly IChatManager _chat = default!; [Dependency] private readonly IAdminManager _admins = default!; - private ISawmill _sawmill = default!; + private readonly ISawmill _sawmill; private NetUserId? PlayerId { get; set; } private string PlayerName { get; set; } = string.Empty; @@ -35,6 +35,8 @@ public sealed class BanPanelEui : BaseEui, IPostInjectInit public BanPanelEui() { IoCManager.InjectDependencies(this); + + _sawmill = _log.GetSawmill("admin.bans_eui"); } public override EuiStateBase GetNewState() @@ -185,9 +187,4 @@ public sealed class BanPanelEui : BaseEui, IPostInjectInit StateDirty(); } - - public void PostInject() - { - _sawmill = _log.GetSawmill("admin.bans_eui"); - } }