Fix TryGetActionData error triggering when run on deleting entities (#27839)

* Fix TryGetActionData error triggering when run on deleting entities

* Only get metadata once
This commit is contained in:
ShadowCommander
2024-05-30 17:25:13 -07:00
committed by GitHub
parent 9df7f5cd2f
commit c6b22fb01c

View File

@@ -112,7 +112,7 @@ public abstract class SharedActionsSystem : EntitySystem
bool logError = true)
{
result = null;
if (!Exists(uid))
if (uid == null || TerminatingOrDeleted(uid.Value))
return false;
var ev = new GetActionDataEvent();