From b5a3f2fe32c1eb8c3d47b7c39f34c5bf0aeaf5a1 Mon Sep 17 00:00:00 2001 From: Dev Date: Wed, 20 Dec 2023 00:27:27 +0000 Subject: [PATCH] Additional tye improvements --- project/src/callbacks/DialogueCallbacks.ts | 4 ++-- project/src/callbacks/GameCallbacks.ts | 3 ++- project/src/callbacks/NotifierCallbacks.ts | 1 + project/src/callbacks/RagfairCallbacks.ts | 3 ++- 4 files changed, 7 insertions(+), 4 deletions(-) diff --git a/project/src/callbacks/DialogueCallbacks.ts b/project/src/callbacks/DialogueCallbacks.ts index ee981d1f..804e7344 100644 --- a/project/src/callbacks/DialogueCallbacks.ts +++ b/project/src/callbacks/DialogueCallbacks.ts @@ -224,14 +224,14 @@ export class DialogueCallbacks implements OnUpdate /** Handle client/friend/ignore/set */ // eslint-disable-next-line @typescript-eslint/no-unused-vars - public ignoreFriend(url: string, request: { uid: string; }, sessionID: string): any + public ignoreFriend(url: string, request: { uid: string; }, sessionID: string): INullResponseData { return this.httpResponse.nullResponse(); } /** Handle client/friend/ignore/remove */ // eslint-disable-next-line @typescript-eslint/no-unused-vars - public unIgnoreFriend(url: string, request: { uid: string; }, sessionID: string): any + public unIgnoreFriend(url: string, request: { uid: string; }, sessionID: string): INullResponseData { return this.httpResponse.nullResponse(); } diff --git a/project/src/callbacks/GameCallbacks.ts b/project/src/callbacks/GameCallbacks.ts index 1bd895f2..6b85af02 100644 --- a/project/src/callbacks/GameCallbacks.ts +++ b/project/src/callbacks/GameCallbacks.ts @@ -11,6 +11,7 @@ import { IGameKeepAliveResponse } from "@spt-aki/models/eft/game/IGameKeepAliveR import { IGameLogoutResponseData } from "@spt-aki/models/eft/game/IGameLogoutResponseData"; import { IGameStartResponse } from "@spt-aki/models/eft/game/IGameStartResponse"; import { IGetRaidTimeRequest } from "@spt-aki/models/eft/game/IGetRaidTimeRequest"; +import { IGetRaidTimeResponse } from "@spt-aki/models/eft/game/IGetRaidTimeResponse"; import { IReportNicknameRequestData } from "@spt-aki/models/eft/game/IReportNicknameRequestData"; import { IServerDetails } from "@spt-aki/models/eft/game/IServerDetails"; import { IVersionValidateRequestData } from "@spt-aki/models/eft/game/IVersionValidateRequestData"; @@ -164,7 +165,7 @@ export class GameCallbacks implements OnLoad * @returns string */ // eslint-disable-next-line @typescript-eslint/no-unused-vars - public getRaidTime(url: string, request: IGetRaidTimeRequest, sessionID: string): any + public getRaidTime(url: string, request: IGetRaidTimeRequest, sessionID: string): IGetRaidTimeResponse { return this.httpResponse.noBody(this.gameController.getRaidTime(sessionID, request)); } diff --git a/project/src/callbacks/NotifierCallbacks.ts b/project/src/callbacks/NotifierCallbacks.ts index baab1b3a..595cde68 100644 --- a/project/src/callbacks/NotifierCallbacks.ts +++ b/project/src/callbacks/NotifierCallbacks.ts @@ -44,6 +44,7 @@ export class NotifierCallbacks /** Handle push/notifier/get */ /** Handle push/notifier/getwebsocket */ + // TODO: removed from client? // eslint-disable-next-line @typescript-eslint/no-unused-vars public getNotifier(url: string, info: any, sessionID: string): IGetBodyResponseData { diff --git a/project/src/callbacks/RagfairCallbacks.ts b/project/src/callbacks/RagfairCallbacks.ts index cd8b1d11..1c23a28d 100644 --- a/project/src/callbacks/RagfairCallbacks.ts +++ b/project/src/callbacks/RagfairCallbacks.ts @@ -13,6 +13,7 @@ import { IExtendOfferRequestData } from "@spt-aki/models/eft/ragfair/IExtendOffe import { IGetItemPriceResult } from "@spt-aki/models/eft/ragfair/IGetItemPriceResult"; import { IGetMarketPriceRequestData } from "@spt-aki/models/eft/ragfair/IGetMarketPriceRequestData"; import { IGetOffersResult } from "@spt-aki/models/eft/ragfair/IGetOffersResult"; +import { IGetRagfairOfferByIdRequest } from "@spt-aki/models/eft/ragfair/IGetRagfairOfferByIdRequest"; import { IRagfairOffer } from "@spt-aki/models/eft/ragfair/IRagfairOffer"; import { IRemoveOfferRequestData } from "@spt-aki/models/eft/ragfair/IRemoveOfferRequestData"; import { ISearchRequestData } from "@spt-aki/models/eft/ragfair/ISearchRequestData"; @@ -145,7 +146,7 @@ export class RagfairCallbacks implements OnLoad, OnUpdate } /** Handle client/ragfair/offer/findbyid */ - public getFleaOfferById(url: string, request: any, sessionID: string): IGetBodyResponseData + public getFleaOfferById(url: string, request: IGetRagfairOfferByIdRequest, sessionID: string): IGetBodyResponseData { return this.httpResponse.getBody(this.ragfairController.getOfferById(sessionID, request)); }