From 18b28a6d0b994a902e8b61703a78c5f0df30461e Mon Sep 17 00:00:00 2001 From: Dev Date: Fri, 5 Apr 2024 21:46:28 +0100 Subject: [PATCH] Remove unused `/singleplayer/settings/weapon/durability` endpoint --- project/assets/configs/inraid.json | 3 +-- project/src/callbacks/InraidCallbacks.ts | 9 --------- project/src/models/spt/config/IInRaidConfig.ts | 1 - project/src/routers/static/InraidStaticRouter.ts | 7 ------- 4 files changed, 1 insertion(+), 19 deletions(-) diff --git a/project/assets/configs/inraid.json b/project/assets/configs/inraid.json index 5bbe48cc..97085b3d 100644 --- a/project/assets/configs/inraid.json +++ b/project/assets/configs/inraid.json @@ -11,8 +11,7 @@ "randomTime": false }, "save": { - "loot": true, - "durability": true + "loot": true }, "carExtracts": [ "Dorms V-Ex", diff --git a/project/src/callbacks/InraidCallbacks.ts b/project/src/callbacks/InraidCallbacks.ts index 005284c5..87a5dec2 100644 --- a/project/src/callbacks/InraidCallbacks.ts +++ b/project/src/callbacks/InraidCallbacks.ts @@ -65,15 +65,6 @@ export class InraidCallbacks return this.httpResponse.noBody(this.inraidController.getInraidConfig().raidMenuSettings); } - /** - * Handle singleplayer/settings/weapon/durability - * @returns - */ - public getWeaponDurability(): string - { - return this.httpResponse.noBody(this.inraidController.getInraidConfig().save.durability); - } - /** * Handle singleplayer/airdrop/config * @returns JSON as string diff --git a/project/src/models/spt/config/IInRaidConfig.ts b/project/src/models/spt/config/IInRaidConfig.ts index 0f836fcb..f3dd433a 100644 --- a/project/src/models/spt/config/IInRaidConfig.ts +++ b/project/src/models/spt/config/IInRaidConfig.ts @@ -42,5 +42,4 @@ export interface Save { /** Should loot gained from raid be saved */ loot: boolean; - durability: boolean; } diff --git a/project/src/routers/static/InraidStaticRouter.ts b/project/src/routers/static/InraidStaticRouter.ts index f2835755..a0f77653 100644 --- a/project/src/routers/static/InraidStaticRouter.ts +++ b/project/src/routers/static/InraidStaticRouter.ts @@ -20,13 +20,6 @@ export class InraidStaticRouter extends StaticRouter return this.inraidCallbacks.getRaidEndState(); }, ), - new RouteAction( - "/singleplayer/settings/weapon/durability", - (url: string, info: any, sessionID: string, output: string): any => - { - return this.inraidCallbacks.getWeaponDurability(); - }, - ), new RouteAction( "/singleplayer/settings/raid/menu", (url: string, info: any, sessionID: string, output: string): any =>