Skip to content

Commit

Permalink
Renamed functions to better match their purpose
Browse files Browse the repository at this point in the history
  • Loading branch information
Chomp committed Jan 17, 2025
1 parent de00ac3 commit 5c29c89
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 8 deletions.
12 changes: 8 additions & 4 deletions project/src/callbacks/CustomizationCallbacks.ts
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,12 @@ export class CustomizationCallbacks {
/**
* Handle CustomizationBuy event
*/
public buyClothing(pmcData: IPmcData, body: IBuyClothingRequestData, sessionID: string): IItemEventRouterResponse {
return this.customizationController.buyClothing(pmcData, body, sessionID);
public buyCustomisation(
pmcData: IPmcData,
body: IBuyClothingRequestData,
sessionID: string,
): IItemEventRouterResponse {
return this.customizationController.buyCustomisation(pmcData, body, sessionID);
}

/** Handle client/hideout/customization/offer/list */
Expand All @@ -69,11 +73,11 @@ export class CustomizationCallbacks {
}

/** Handle CustomizationSet */
public setClothing(
public setCustomisation(
pmcData: IPmcData,
request: ICustomizationSetRequest,
sessionID: string,
): IItemEventRouterResponse {
return this.customizationController.setClothing(sessionID, request, pmcData);
return this.customizationController.setCustomisation(sessionID, request, pmcData);
}
}
4 changes: 2 additions & 2 deletions project/src/controllers/CustomizationController.ts
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ export class CustomizationController {
* @param sessionId Session id
* @returns IItemEventRouterResponse
*/
public buyClothing(
public buyCustomisation(
pmcData: IPmcData,
buyClothingRequest: IBuyClothingRequestData,
sessionId: string,
Expand Down Expand Up @@ -252,7 +252,7 @@ export class CustomizationController {
}

/** Handle CustomizationSet event */
public setClothing(
public setCustomisation(
sessionId: string,
request: ICustomizationSetRequest,
pmcData: IPmcData,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@ export class CustomizationItemEventRouter extends ItemEventRouterDefinition {
): Promise<IItemEventRouterResponse> {
switch (url) {
case "CustomizationBuy":
return this.customizationCallbacks.buyClothing(pmcData, body, sessionID);
return this.customizationCallbacks.buyCustomisation(pmcData, body, sessionID);
case "CustomizationSet":
return this.customizationCallbacks.setClothing(pmcData, body, sessionID);
return this.customizationCallbacks.setCustomisation(pmcData, body, sessionID);
}
}
}

0 comments on commit 5c29c89

Please sign in to comment.