From 2b0c618222ff50dfe3bbfd236c8f66aa7abac7b0 Mon Sep 17 00:00:00 2001 From: phyzical Date: Thu, 7 Apr 2022 16:31:31 +0800 Subject: [PATCH] fix build error with fix for augmentations not being static --- src/Augmentation/AugmentationHelpers.tsx | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/Augmentation/AugmentationHelpers.tsx b/src/Augmentation/AugmentationHelpers.tsx index a48424a74..e47d2b76d 100644 --- a/src/Augmentation/AugmentationHelpers.tsx +++ b/src/Augmentation/AugmentationHelpers.tsx @@ -95,10 +95,11 @@ function updateNeuroFluxGovernorCosts(neuroFluxGovernorAugmentation: Augmentatio } function updateInfiltratorCosts(infiltratorAugmentation: Augmentation): void { + const infiltratorAugmentationNames = initInfiltratorsAugmentations().map((augmentation) => augmentation.name); const infiltratorMultiplier = - infiltratorsAugmentations.filter((augmentation) => Player.hasAugmentation(augmentation.name)).length + 1; + infiltratorAugmentationNames.filter((augmentationName) => Player.hasAugmentation(augmentationName)).length + 1; infiltratorAugmentation.baseCost = Math.pow(infiltratorAugmentation.startingCost * 1000, infiltratorMultiplier); - if (infiltratorsAugmentations.find((augmentation) => augmentation.name === infiltratorAugmentation.name)) { + if (infiltratorAugmentationNames.find((augmentationName) => augmentationName === infiltratorAugmentation.name)) { infiltratorAugmentation.baseRepRequirement = infiltratorAugmentation.startingRepRequirement * infiltratorMultiplier; } }