diff --git a/src/controllers/custom/unlockLevelCupController.ts b/src/controllers/custom/unlockLevelCapController.ts similarity index 83% rename from src/controllers/custom/unlockLevelCupController.ts rename to src/controllers/custom/unlockLevelCapController.ts index 367e2555..a528f259 100644 --- a/src/controllers/custom/unlockLevelCupController.ts +++ b/src/controllers/custom/unlockLevelCapController.ts @@ -4,9 +4,9 @@ import { broadcastInventoryUpdate } from "../../services/wsService.ts"; import { getInventory } from "../../services/inventoryService.ts"; import type { TEquipmentKey } from "../../types/inventoryTypes/inventoryTypes.ts"; -export const unlockLevelCupController: RequestHandler = async (req, res) => { +export const unlockLevelCapController: RequestHandler = async (req, res) => { const accountId = await getAccountIdForRequest(req); - const data = req.body as IUnlockLevelCupRequest; + const data = req.body as IunlockLevelCapRequest; const inventory = await getInventory(accountId, data.Category); const equipment = inventory[data.Category].id(data.ItemId)!; @@ -18,7 +18,7 @@ export const unlockLevelCupController: RequestHandler = async (req, res) => { broadcastInventoryUpdate(req); }; -interface IUnlockLevelCupRequest { +interface IunlockLevelCapRequest { Category: TEquipmentKey; ItemId: string; Polarized: number; diff --git a/src/routes/custom.ts b/src/routes/custom.ts index e5e164c2..7eb8fafa 100644 --- a/src/routes/custom.ts +++ b/src/routes/custom.ts @@ -41,7 +41,7 @@ import { manageQuestsController } from "../controllers/custom/manageQuestsContro import { setEvolutionProgressController } from "../controllers/custom/setEvolutionProgressController.ts"; import { setBoosterController } from "../controllers/custom/setBoosterController.ts"; import { updateFingerprintController } from "../controllers/custom/updateFingerprintController.ts"; -import { unlockLevelCupController } from "../controllers/custom/unlockLevelCupController.ts"; +import { unlockLevelCapController } from "../controllers/custom/unlockLevelCapController.ts"; import { changeModularPartsController } from "../controllers/custom/changeModularPartsController.ts"; import { editSuitInvigorationUpgradeController } from "../controllers/custom/editSuitInvigorationUpgradeController.ts"; import { setAccountCheatController } from "../controllers/custom/setAccountCheatController.ts"; @@ -90,7 +90,7 @@ customRouter.post("/manageQuests", manageQuestsController); customRouter.post("/setEvolutionProgress", setEvolutionProgressController); customRouter.post("/setBooster", setBoosterController); customRouter.post("/updateFingerprint", updateFingerprintController); -customRouter.post("/unlockLevelCup", unlockLevelCupController); +customRouter.post("/unlockLevelCap", unlockLevelCapController); customRouter.post("/changeModularParts", changeModularPartsController); customRouter.post("/editSuitInvigorationUpgrade", editSuitInvigorationUpgradeController); customRouter.post("/setAccountCheat", setAccountCheatController); diff --git a/static/webui/script.js b/static/webui/script.js index a43773bc..ba0eb682 100644 --- a/static/webui/script.js +++ b/static/webui/script.js @@ -822,7 +822,7 @@ function updateInventory() { a.href = "#"; a.onclick = function (event) { event.preventDefault(); - unlockLevelCup( + unlockLevelCap( category, item.ItemId.$oid, (itemMap[item.ItemType].maxLevelCap - 30) / 2 @@ -2774,10 +2774,10 @@ function gildEquipment(category, oid) { }); } -function unlockLevelCup(category, oid, formas) { +function unlockLevelCap(category, oid, formas) { revalidateAuthz().then(() => { $.post({ - url: "/custom/unlockLevelCup?" + window.authz, + url: "/custom/unlockLevelCap?" + window.authz, contentType: "application/json", data: JSON.stringify({ Category: category,