From 0ac9e147cb6892baa1be255dc4b838b8c6bb3f6a Mon Sep 17 00:00:00 2001 From: Refringe Date: Thu, 16 Nov 2023 10:07:46 -0500 Subject: [PATCH] Resolved post-conflict syntax errors. Sorry! --- project/src/di/Container.ts | 59 +------------------ project/src/helpers/InventoryHelper.ts | 4 +- .../src/routers/static/DataStaticRouter.ts | 3 - 3 files changed, 3 insertions(+), 63 deletions(-) diff --git a/project/src/di/Container.ts b/project/src/di/Container.ts index fd9e87d6..3b041d88 100644 --- a/project/src/di/Container.ts +++ b/project/src/di/Container.ts @@ -353,19 +353,13 @@ export class Container // Utils con.register("App", App, { lifecycle: Lifecycle.Singleton }); con.register("DatabaseImporter", DatabaseImporter, { lifecycle: Lifecycle.Singleton }); - lifecycle: Lifecycle.Singleton, - }); con.register("HashUtil", HashUtil, { lifecycle: Lifecycle.Singleton }); con.register("ImporterUtil", ImporterUtil, { lifecycle: Lifecycle.Singleton }); con.register("HttpResponseUtil", HttpResponseUtil); con.register("EncodingUtil", EncodingUtil, { lifecycle: Lifecycle.Singleton }); con.register("JsonUtil", JsonUtil); con.register("WinstonLogger", WinstonMainLogger, { lifecycle: Lifecycle.Singleton }); - lifecycle: Lifecycle.Singleton, - }); con.register("RequestsLogger", WinstonRequestLogger, { lifecycle: Lifecycle.Singleton }); - lifecycle: Lifecycle.Singleton, - }); con.register("MathUtil", MathUtil, { lifecycle: Lifecycle.Singleton }); con.register("ObjectId", ObjectId); con.register("RandomUtil", RandomUtil, { lifecycle: Lifecycle.Singleton }); @@ -385,8 +379,6 @@ export class Container con.register("HttpRouter", HttpRouter, { lifecycle: Lifecycle.Singleton }); con.register("ImageRouter", ImageRouter); con.register("EventOutputHolder", EventOutputHolder, { lifecycle: Lifecycle.Singleton }); - lifecycle: Lifecycle.Singleton, - }); con.register("ItemEventRouter", ItemEventRouter); // Dynamic routes @@ -409,11 +401,7 @@ export class Container con.register("HealthItemEventRouter", { useClass: HealthItemEventRouter }); con.register("HideoutItemEventRouter", { useClass: HideoutItemEventRouter }); con.register("InsuranceItemEventRouter", { useClass: InsuranceItemEventRouter }); - useClass: InsuranceItemEventRouter, - }); con.register("InventoryItemEventRouter", { useClass: InventoryItemEventRouter }); - useClass: InventoryItemEventRouter, - }); con.register("NoteItemEventRouter", { useClass: NoteItemEventRouter }); con.register("PresetBuildItemEventRouter", { useClass: PresetBuildItemEventRouter, @@ -423,15 +411,11 @@ export class Container con.register("RepairItemEventRouter", { useClass: RepairItemEventRouter }); con.register("TradeItemEventRouter", { useClass: TradeItemEventRouter }); con.register("WishlistItemEventRouter", { useClass: WishlistItemEventRouter }); - useClass: WishlistItemEventRouter, - }); // save load routes con.register("HealthSaveLoadRouter", { useClass: HealthSaveLoadRouter }); con.register("InraidSaveLoadRouter", { useClass: InraidSaveLoadRouter }); con.register("InsuranceSaveLoadRouter", { useClass: InsuranceSaveLoadRouter }); - useClass: InsuranceSaveLoadRouter, - }); con.register("ProfileSaveLoadRouter", { useClass: ProfileSaveLoadRouter }); // Route serializers @@ -444,8 +428,6 @@ export class Container con.register("BundleStaticRouter", { useClass: BundleStaticRouter }); con.register("ClientLogStaticRouter", { useClass: ClientLogStaticRouter }); con.register("CustomizationStaticRouter", { useClass: CustomizationStaticRouter }); - useClass: CustomizationStaticRouter, - }); con.register("DataStaticRouter", { useClass: DataStaticRouter }); con.register("DialogStaticRouter", { useClass: DialogStaticRouter }); con.register("GameStaticRouter", { useClass: GameStaticRouter }); @@ -477,7 +459,7 @@ export class Container con.register("ScavCaseRewardGenerator", ScavCaseRewardGenerator, { lifecycle: Lifecycle.Singleton, }); - depContainer.register("ScavCaseRewardGenerator", ScavCaseRewardGenerator, { + con.register("ScavCaseRewardGenerator", ScavCaseRewardGenerator, { lifecycle: Lifecycle.Singleton, }); con.register("RagfairAssortGenerator", { useClass: RagfairAssortGenerator }); @@ -486,18 +468,12 @@ export class Container con.register("PlayerScavGenerator", { useClass: PlayerScavGenerator }); con.register("LootGenerator", { useClass: LootGenerator }); con.register("FenceBaseAssortGenerator", { useClass: FenceBaseAssortGenerator }); - useClass: FenceBaseAssortGenerator, - }); con.register("BotLevelGenerator", { useClass: BotLevelGenerator }); con.register("BotEquipmentModGenerator", { useClass: BotEquipmentModGenerator }); - useClass: BotEquipmentModGenerator, - }); con.register("RepeatableQuestGenerator", { useClass: RepeatableQuestGenerator }); con.register("BarrelInventoryMagGen", { useClass: BarrelInventoryMagGen }); con.register("ExternalInventoryMagGen", { useClass: ExternalInventoryMagGen }); - useClass: ExternalInventoryMagGen, - }); con.register("InternalMagazineInventoryMagGen", { useClass: InternalMagazineInventoryMagGen, }); @@ -538,8 +514,6 @@ export class Container con.register("RepairHelper", { useClass: RepairHelper }); con.register("TraderHelper", TraderHelper); con.register("TraderAssortHelper", TraderAssortHelper, { lifecycle: Lifecycle.Singleton }); - lifecycle: Lifecycle.Singleton, - }); con.register("TradeHelper", { useClass: TradeHelper }); con.register("NotifierHelper", { useClass: NotifierHelper }); con.register("UtilityHelper", UtilityHelper); @@ -549,8 +523,6 @@ export class Container con.register("SecureContainerHelper", { useClass: SecureContainerHelper }); con.register("ProbabilityHelper", { useClass: ProbabilityHelper }); con.register("BotWeaponGeneratorHelper", { useClass: BotWeaponGeneratorHelper }); - useClass: BotWeaponGeneratorHelper, - }); con.register("BotDifficultyHelper", { useClass: BotDifficultyHelper }); con.register("RepeatableQuestHelper", { useClass: RepeatableQuestHelper }); } @@ -561,8 +533,6 @@ export class Container con.register("BundleLoader", BundleLoader, { lifecycle: Lifecycle.Singleton }); con.register("PreAkiModLoader", PreAkiModLoader, { lifecycle: Lifecycle.Singleton }); con.register("PostAkiModLoader", PostAkiModLoader, { lifecycle: Lifecycle.Singleton }); - lifecycle: Lifecycle.Singleton, - }); } private static registerCallbacks(con: DependencyContainer): void @@ -607,15 +577,11 @@ export class Container { // Services con.register("ImageRouteService", ImageRouteService, { lifecycle: Lifecycle.Singleton }); - lifecycle: Lifecycle.Singleton, - }); con.register("FenceService", FenceService, { lifecycle: Lifecycle.Singleton }); con.register("PlayerService", { useClass: PlayerService }); con.register("PaymentService", { useClass: PaymentService }); con.register("InsuranceService", InsuranceService, { lifecycle: Lifecycle.Singleton }); - lifecycle: Lifecycle.Singleton, - }); con.register("TraderAssortService", TraderAssortService, { lifecycle: Lifecycle.Singleton, }); @@ -639,22 +605,7 @@ export class Container con.register("NotificationService", NotificationService, { lifecycle: Lifecycle.Singleton, }); - depContainer.register("MatchLocationService", MatchLocationService, { - lifecycle: Lifecycle.Singleton, - }); - depContainer.register("ModCompilerService", ModCompilerService); - depContainer.register("HashCacheService", HashCacheService, { - lifecycle: Lifecycle.Singleton, - }); - depContainer.register("LocaleService", LocaleService, { lifecycle: Lifecycle.Singleton }); - depContainer.register("ProfileFixerService", ProfileFixerService); - depContainer.register("RepairService", RepairService); - depContainer.register("BotLootCacheService", BotLootCacheService, { - lifecycle: Lifecycle.Singleton, - }); con.register("MatchLocationService", MatchLocationService, { - depContainer.register("BotEquipmentFilterService", BotEquipmentFilterService); - depContainer.register("ProfileSnapshotService", ProfileSnapshotService, { lifecycle: Lifecycle.Singleton, }); con.register("ModCompilerService", ModCompilerService); @@ -678,7 +629,6 @@ export class Container lifecycle: Lifecycle.Singleton, }); con.register("CustomLocationWaveService", CustomLocationWaveService, { - depContainer.register("ItemBaseClassService", ItemBaseClassService, { lifecycle: Lifecycle.Singleton, }); con.register("OpenZoneService", OpenZoneService, { lifecycle: Lifecycle.Singleton }); @@ -699,9 +649,6 @@ export class Container }); con.register("RagfairTaxService", RagfairTaxService, { lifecycle: Lifecycle.Singleton }); con.register("TraderPurchasePersisterService", TraderPurchasePersisterService); - "TraderPurchasePersisterService", - TraderPurchasePersisterService, - ); con.register("PmcChatResponseService", PmcChatResponseService); con.register("GiftService", GiftService); con.register("MailSendService", MailSendService); @@ -724,8 +671,6 @@ export class Container con.register("BotController", { useClass: BotController }); con.register("ClientLogController", { useClass: ClientLogController }); con.register("CustomizationController", { useClass: CustomizationController }); - useClass: CustomizationController, - }); con.register("DialogueController", { useClass: DialogueController }); con.register("GameController", { useClass: GameController }); con.register("HandbookController", { useClass: HandbookController }); @@ -746,8 +691,6 @@ export class Container con.register("RagfairController", { useClass: RagfairController }); con.register("RepairController", { useClass: RepairController }); con.register("RepeatableQuestController", { useClass: RepeatableQuestController }); - useClass: RepeatableQuestController, - }); con.register("TradeController", { useClass: TradeController }); con.register("TraderController", { useClass: TraderController }); con.register("WeatherController", { useClass: WeatherController }); diff --git a/project/src/helpers/InventoryHelper.ts b/project/src/helpers/InventoryHelper.ts index 66b98fa0..497b0c00 100644 --- a/project/src/helpers/InventoryHelper.ts +++ b/project/src/helpers/InventoryHelper.ts @@ -315,9 +315,9 @@ export class InventoryHelper const itemLocation = {}; // Item already has location property, use it - if (itemLib[tmpKey].location !== undefined) + if (itemLib[tmpKey]["location"] !== undefined) { - itemLocation.location = itemLib[tmpKey].location; + itemLocation["location"] = itemLib[tmpKey]["location"]; } output.profileChanges[sessionID].items.new.push({ diff --git a/project/src/routers/static/DataStaticRouter.ts b/project/src/routers/static/DataStaticRouter.ts index 422910cc..cbb7e7a0 100644 --- a/project/src/routers/static/DataStaticRouter.ts +++ b/project/src/routers/static/DataStaticRouter.ts @@ -67,9 +67,6 @@ export class DataStaticRouter extends StaticRouter new RouteAction("/client/languages", (url: string, info: any, sessionID: string, output: string): any => { return this.dataCallbacks.getLocalesLanguages(url, info, sessionID); - (url: string, info: any, sessionID: string, output: string): any => - { - return this.dataCallbacks.getLocalesLanguages(url, info, sessionID); }), new RouteAction( "/client/hideout/qte/list",