Skip to content

Commit b3e1c9c

Browse files
committed
missing check for null
1 parent 9126fa1 commit b3e1c9c

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

CathodeLib/Scripts/CATHODE/CommandsPAK/Helpers/ShortGuidUtils.cs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,8 +41,9 @@ public static void LinkCommands(Commands commands)
4141
_commands.OnSaveSuccess -= SaveCustomNames;
4242

4343
_commands = commands;
44-
if (_commands != null)
45-
_commands.OnSaveSuccess += SaveCustomNames;
44+
if (_commands == null) return;
45+
46+
_commands.OnSaveSuccess += SaveCustomNames;
4647

4748
LoadCustomNames(commands.Filepath);
4849
}

0 commit comments

Comments
 (0)