mirror of
https://github.com/duckietm/Nitro-V3.git
synced 2026-06-19 15:06:20 +00:00
Add optional clone() to IPurchasableOffer
useCatalog's localization-refresh effect calls 'offer?.clone ? offer.clone() : offer' to mint fresh references when locale strings change. Offer.ts implements clone() but the interface didn't declare it, so the guarded call broke tsgo. FurnitureOffer (the lazy wrapper) doesn't implement clone — and the call site is guarded — so 'clone?(): IPurchasableOffer' (optional) keeps the interface honest without forcing FurnitureOffer to grow a no-op clone. Net tsgo error count: -4.
This commit is contained in:
@@ -24,4 +24,5 @@ export interface IPurchasableOffer
|
||||
products: IProduct[];
|
||||
itemIds: string;
|
||||
haveOffer: boolean;
|
||||
clone?(): IPurchasableOffer;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user