Replace all T : Component constraints with T : IComponent (#21073)
This commit is contained in:
@@ -1,8 +1,5 @@
|
||||
using System.Diagnostics.CodeAnalysis;
|
||||
using Content.Shared.Alert;
|
||||
using Content.Shared.Mobs;
|
||||
using Content.Shared.Mobs.Components;
|
||||
using Content.Shared.Mobs.Systems;
|
||||
using Content.Shared.Rejuvenate;
|
||||
using Robust.Shared.GameStates;
|
||||
using Robust.Shared.Prototypes;
|
||||
@@ -107,7 +104,7 @@ namespace Content.Shared.StatusEffect
|
||||
/// <typeparam name="T">The component type to add and remove from the entity.</typeparam>
|
||||
public bool TryAddStatusEffect<T>(EntityUid uid, string key, TimeSpan time, bool refresh,
|
||||
StatusEffectsComponent? status = null)
|
||||
where T : Component, new()
|
||||
where T : IComponent, new()
|
||||
{
|
||||
if (!Resolve(uid, ref status, false))
|
||||
return false;
|
||||
|
||||
Reference in New Issue
Block a user