Skip to content

Commit

Permalink
fix id card console not updating records (#28237)
Browse files Browse the repository at this point in the history
* fix id card console not updating records

* test

---------

Co-authored-by: deltanedas <@deltanedas:kde.org>
  • Loading branch information
deltanedas committed May 25, 2024
1 parent 8619f24 commit 37ad81c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Content.Server/Access/Systems/IdCardConsoleSystem.cs
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,8 @@ private void UpdateUserInterface(EntityUid uid, IdCardConsoleComponent component
_idCard.TryChangeJobDepartment(targetId, job);
}

UpdateStationRecord(uid, targetId, newFullName, newJobTitle, job);

if (!newAccessList.TrueForAll(x => component.AccessLevels.Contains(x)))
{
_sawmill.Warning($"User {ToPrettyString(uid)} tried to write unknown access tag.");
Expand Down Expand Up @@ -168,8 +170,6 @@ private void UpdateUserInterface(EntityUid uid, IdCardConsoleComponent component
This current implementation is pretty shit as it logs 27 entries (27 lines) if someone decides to give themselves AA*/
_adminLogger.Add(LogType.Action, LogImpact.Medium,
$"{ToPrettyString(player):player} has modified {ToPrettyString(targetId):entity} with the following accesses: [{string.Join(", ", addedTags.Union(removedTags))}] [{string.Join(", ", newAccessList)}]");

UpdateStationRecord(uid, targetId, newFullName, newJobTitle, job);
}

/// <summary>
Expand Down

0 comments on commit 37ad81c

Please sign in to comment.