diff --git a/src/services/missionInventoryUpdateService.ts b/src/services/missionInventoryUpdateService.ts index 5a68ad8a..81860b36 100644 --- a/src/services/missionInventoryUpdateService.ts +++ b/src/services/missionInventoryUpdateService.ts @@ -1542,19 +1542,11 @@ export const addMissionRewards = async ( }, { endings: ["Jobs/NewbieJob"], amount: 200, tag: "CetusSyndicate" } ]; - if (specialCase.some(rule => rule.endings.some(e => jobType.endsWith(e)))) { - const specialCaseReward = specialCase.find( - rule => - rule.endings.some(e => jobType.endsWith(e)) && - (rule.stage === undefined || rewardInfo.JobStage === rule.stage) - ); + const match = specialCase.find(rule => rule.endings.some(e => jobType.endsWith(e))); + if (match) { + const specialCaseReward = match.stage === undefined || rewardInfo.JobStage === match.stage ? match : null; if (specialCaseReward) { - addStanding( - inventory, - specialCaseReward.tag, - Math.floor(specialCaseReward.amount / (rewardInfo.Q ? 0.8 : 1)), - AffiliationMods - ); + addStanding(inventory, match.tag, Math.floor(match.amount / (rewardInfo.Q ? 0.8 : 1)), AffiliationMods); } } else if (syndicateEntry && syndicateEntry.Jobs) { let currentJob = syndicateEntry.Jobs[rewardInfo.JobTier!];