Fixed null issues

This commit is contained in:
Chomp
2025-01-22 19:53:25 +00:00
parent d5d07f3bc1
commit 7b0379bc5c
2 changed files with 2 additions and 1 deletions
+1 -1
View File
@@ -1822,7 +1822,7 @@ public class ItemHelper(
foreach (var mod in itemWithChildren)
{
if (idMappings[mod.Id] is null)
if (!idMappings.ContainsKey(mod.Id))
{
idMappings[mod.Id] = _hashUtil.Generate();
}
+1
View File
@@ -218,6 +218,7 @@ namespace Core.Helpers
pmcData.UnlockedInfo.UnlockedProductionRecipe.Add(matchingCraftId);
if (response is not null)
{
response.ProfileChanges[sessionID].RecipeUnlocked ??= new Dictionary<string, bool>();
response.ProfileChanges[sessionID].RecipeUnlocked[matchingCraftId] = true;
}
}