From: Leon Friedrich <60421075+ElectroJr@users.noreply.github.com> Date: Sun, 19 Nov 2023 02:10:27 +0000 (+1300) Subject: Fix storage exception (#21752) X-Git-Url: https://git.smokeofanarchy.ru/gitweb.cgi?a=commitdiff_plain;h=8892e9e3ae4982cb3b9d374b18fb5fc4d52020bf;p=space-station-14.git Fix storage exception (#21752) --- diff --git a/Content.Shared/Storage/EntitySystems/SharedStorageSystem.cs b/Content.Shared/Storage/EntitySystems/SharedStorageSystem.cs index 88e263b556..ef7930fe2b 100644 --- a/Content.Shared/Storage/EntitySystems/SharedStorageSystem.cs +++ b/Content.Shared/Storage/EntitySystems/SharedStorageSystem.cs @@ -390,6 +390,10 @@ public abstract class SharedStorageSystem : EntitySystem if (!Resolve(uid, ref storage, ref appearance, false)) return; + // ReSharper disable once ConditionIsAlwaysTrueOrFalseAccordingToNullableAPIContract + if (storage.Container == null) + return; // component hasn't yet been initialized. + int capacity; int used; if (storage.MaxSlots == null)