From 96da3d1c6bfe4967695c8db95e626aab08b45e91 Mon Sep 17 00:00:00 2001 From: Dev Date: Tue, 11 Apr 2023 16:52:07 +0100 Subject: [PATCH] nullguard generatePool() function inside `BotEquipmentModPoolService` --- project/src/services/BotEquipmentModPoolService.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/project/src/services/BotEquipmentModPoolService.ts b/project/src/services/BotEquipmentModPoolService.ts index 23d08f46..72950a3c 100644 --- a/project/src/services/BotEquipmentModPoolService.ts +++ b/project/src/services/BotEquipmentModPoolService.ts @@ -83,7 +83,7 @@ export class BotEquipmentModPoolService // Check item added into array for slots, need to iterate over those const subItemDetails = this.databaseServer.getTables().templates.items[itemToAdd]; - const hasSubItemsToAdd = subItemDetails._props.Slots?.length > 0; + const hasSubItemsToAdd = subItemDetails?._props?.Slots?.length > 0; if (hasSubItemsToAdd) { // Recursive call