From: Tayrtahn Date: Sun, 17 Aug 2025 19:34:47 +0000 (-0400) Subject: Fix error when deleting a toggled `ToggleableClothingComponent` (#39191) X-Git-Url: https://git.smokeofanarchy.ru/gitweb.cgi?a=commitdiff_plain;h=8034cabbaeed60f7f476d1be193c5d476eac8309;p=space-station-14.git Fix error when deleting a toggled `ToggleableClothingComponent` (#39191) --- diff --git a/Content.Shared/Clothing/EntitySystems/ToggleableClothingSystem.cs b/Content.Shared/Clothing/EntitySystems/ToggleableClothingSystem.cs index 334f88af6d..a2b7d01641 100644 --- a/Content.Shared/Clothing/EntitySystems/ToggleableClothingSystem.cs +++ b/Content.Shared/Clothing/EntitySystems/ToggleableClothingSystem.cs @@ -213,7 +213,7 @@ public sealed class ToggleableClothingSystem : EntitySystem if (!TryComp(component.AttachedUid, out ToggleableClothingComponent? toggleComp)) return; - if (toggleComp.LifeStage > ComponentLifeStage.Running) + if (LifeStage(component.AttachedUid) > EntityLifeStage.MapInitialized) return; // As unequipped gets called in the middle of container removal, we cannot call a container-insert without causing issues.