Missing nullables (#8634)
This commit is contained in:
@@ -18,7 +18,7 @@ public sealed class VendingMachineEjectItemWireAction : BaseWireAction
|
||||
var lightState = StatusLightState.Off;
|
||||
|
||||
if (IsPowered(wire.Owner)
|
||||
&& EntityManager.TryGetComponent(wire.Owner, out VendingMachineComponent vending))
|
||||
&& EntityManager.TryGetComponent(wire.Owner, out VendingMachineComponent? vending))
|
||||
{
|
||||
lightState = vending.CanShoot
|
||||
? StatusLightState.BlinkingFast
|
||||
@@ -40,7 +40,7 @@ public sealed class VendingMachineEjectItemWireAction : BaseWireAction
|
||||
|
||||
public override bool Cut(EntityUid user, Wire wire)
|
||||
{
|
||||
if (EntityManager.TryGetComponent(wire.Owner, out VendingMachineComponent vending))
|
||||
if (EntityManager.TryGetComponent(wire.Owner, out VendingMachineComponent? vending))
|
||||
{
|
||||
vending.CanShoot = true;
|
||||
}
|
||||
@@ -50,7 +50,7 @@ public sealed class VendingMachineEjectItemWireAction : BaseWireAction
|
||||
|
||||
public override bool Mend(EntityUid user, Wire wire)
|
||||
{
|
||||
if (EntityManager.TryGetComponent(wire.Owner, out VendingMachineComponent vending))
|
||||
if (EntityManager.TryGetComponent(wire.Owner, out VendingMachineComponent? vending))
|
||||
{
|
||||
vending.CanShoot = false;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user