From: Tayrtahn Date: Fri, 20 Jun 2025 22:11:12 +0000 (-0400) Subject: Forbid string literals for `SharedActionsSystem` methods (#38472) X-Git-Url: https://git.smokeofanarchy.ru/gitweb.cgi?a=commitdiff_plain;h=c1de936c4b89a8b32476316aa117a235c777ef50;p=space-station-14.git Forbid string literals for `SharedActionsSystem` methods (#38472) Forbid string literals for SharedActionsSystem methods --- diff --git a/Content.Shared/Actions/SharedActionsSystem.cs b/Content.Shared/Actions/SharedActionsSystem.cs index 6490dc3c0a..333d87157d 100644 --- a/Content.Shared/Actions/SharedActionsSystem.cs +++ b/Content.Shared/Actions/SharedActionsSystem.cs @@ -579,7 +579,7 @@ public abstract class SharedActionsSystem : EntitySystem #region AddRemoveActions public EntityUid? AddAction(EntityUid performer, - string? actionPrototypeId, + [ForbidLiteral] string? actionPrototypeId, EntityUid container = default, ActionsComponent? component = null) { @@ -599,7 +599,7 @@ public abstract class SharedActionsSystem : EntitySystem /// The entity that contains/enables this action (e.g., flashlight). public bool AddAction(EntityUid performer, [NotNullWhen(true)] ref EntityUid? actionId, - string? actionPrototypeId, + [ForbidLiteral] string? actionPrototypeId, EntityUid container = default, ActionsComponent? component = null) { @@ -610,7 +610,7 @@ public abstract class SharedActionsSystem : EntitySystem public bool AddAction(EntityUid performer, [NotNullWhen(true)] ref EntityUid? actionId, [NotNullWhen(true)] out ActionComponent? action, - string? actionPrototypeId, + [ForbidLiteral] string? actionPrototypeId, EntityUid container = default, ActionsComponent? component = null) {