diff --git a/src/services/purchaseService.ts b/src/services/purchaseService.ts index 48069432..7f0170d2 100644 --- a/src/services/purchaseService.ts +++ b/src/services/purchaseService.ts @@ -99,7 +99,7 @@ export const handlePurchase = async ( Expiry: new Date(parseInt(offer.Expiry.$date.$numberLong)) }); } - prePurchaseInventoryChanges.RecentVendorPurchases = { + prePurchaseInventoryChanges.NewVendorPurchase = { VendorType: manifest.VendorInfo.TypeName, PurchaseHistory: [ { @@ -109,6 +109,7 @@ export const handlePurchase = async ( } ] }; + prePurchaseInventoryChanges.RecentVendorPurchases = prePurchaseInventoryChanges.NewVendorPurchase; } purchaseRequest.PurchaseParams.Quantity *= offer.QuantityMultiplier; } else { diff --git a/src/types/purchaseTypes.ts b/src/types/purchaseTypes.ts index f665f9da..51459454 100644 --- a/src/types/purchaseTypes.ts +++ b/src/types/purchaseTypes.ts @@ -44,7 +44,8 @@ export type IInventoryChanges = { MiscItems?: IMiscItem[]; EmailItems?: ITypeCount[]; Nemesis?: Partial; - RecentVendorPurchases?: IRecentVendorPurchaseClient; + NewVendorPurchase?: IRecentVendorPurchaseClient; // >= 38.5.0 + RecentVendorPurchases?: IRecentVendorPurchaseClient; // < 38.5.0 } & Record< Exclude< string,