diff --git a/Content.Server/Wires/WiresSystem.cs b/Content.Server/Wires/WiresSystem.cs
index 3e75659072..397b199ecb 100644
--- a/Content.Server/Wires/WiresSystem.cs
+++ b/Content.Server/Wires/WiresSystem.cs
@@ -579,14 +579,14 @@ public sealed class WiresSystem : SharedWiresSystem
/// Tries to get all the wires on this entity by the wire action type.
///
/// Enumerator of all wires in this entity according to the given type.
- public IEnumerable TryGetWires(EntityUid uid, WiresComponent? wires = null)
+ public IEnumerable TryGetWires(EntityUid uid, WiresComponent? wires = null) where T: IWireAction
{
if (!Resolve(uid, ref wires))
yield break;
foreach (var wire in wires.WiresList)
{
- if (wire.GetType() == typeof(T))
+ if (wire.Action?.GetType() == typeof(T))
{
yield return wire;
}