handle selection of CET_UPGRADE
All checks were successful
Build / build (push) Successful in 55s
Build / build (pull_request) Successful in 1m34s

This commit is contained in:
Sainan 2025-04-25 07:40:06 +02:00
parent a7f4e661d0
commit ba6d3afd8a

View File

@ -21,6 +21,8 @@ export const completeCalendarEventController: RequestHandler = async (req, res)
if (selection.type == "CET_REWARD") { if (selection.type == "CET_REWARD") {
inventoryChanges = (await handleStoreItemAcquisition(selection.reward!, inventory)) inventoryChanges = (await handleStoreItemAcquisition(selection.reward!, inventory))
.InventoryChanges; .InventoryChanges;
} else if (selection.type == "CET_UPGRADE") {
calendarProgress.YearProgress.Upgrades.push(selection.upgrade!);
} else if (selection.type != "CET_PLOT") { } else if (selection.type != "CET_PLOT") {
throw new Error(`unexpected selection type: ${selection.type}`); throw new Error(`unexpected selection type: ${selection.type}`);
} }