@@ -186,7 +186,7 @@ export function calculateUnrealizedAssetWeight(
186186 quoteSpotMarket : SpotMarketAccount ,
187187 unrealizedPnl : BN ,
188188 marginCategory : MarginCategory ,
189- oraclePriceData : OraclePriceData
189+ oraclePriceData : Pick < OraclePriceData , 'price' >
190190) : BN {
191191 let assetWeight : BN ;
192192 switch ( marginCategory ) {
@@ -252,7 +252,7 @@ export function calculateMarketMaxAvailableInsurance(
252252
253253export function calculateNetUserPnl (
254254 perpMarket : PerpMarketAccount ,
255- oraclePriceData : OraclePriceData
255+ oraclePriceData : Pick < OraclePriceData , 'price' >
256256) : BN {
257257 const netUserPositionValue = perpMarket . amm . baseAssetAmountWithAmm
258258 . add ( perpMarket . amm . baseAssetAmountWithUnsettledLp )
@@ -272,7 +272,7 @@ export function calculateNetUserPnl(
272272export function calculateNetUserPnlImbalance (
273273 perpMarket : PerpMarketAccount ,
274274 spotMarket : SpotMarketAccount ,
275- oraclePriceData : OraclePriceData ,
275+ oraclePriceData : Pick < OraclePriceData , 'price' > ,
276276 applyFeePoolDiscount = true
277277) : BN {
278278 const netUserPnl = calculateNetUserPnl ( perpMarket , oraclePriceData ) ;
0 commit comments