use mmOracleData for auctionParams calc

This commit is contained in:
Nick Caradonna
2025-10-29 18:06:29 -04:00
parent 3a159fae41
commit 94d9e0b627

View File

@@ -1397,7 +1397,7 @@ export const calculateDynamicSlippage = (
try { try {
// Get oracle data // Get oracle data
const oracleData = isPerp const oracleData = isPerp
? driftClient.getOracleDataForPerpMarket(marketIndex) ? driftClient.getMMOracleDataForPerpMarket(marketIndex)
: driftClient.getOracleDataForSpotMarket(marketIndex); : driftClient.getOracleDataForSpotMarket(marketIndex);
// Get oracle price // Get oracle price
@@ -1505,7 +1505,7 @@ export const getEstimatedPricesWithL2 = async (
const oracleData = isSpot const oracleData = isSpot
? driftClient.getOracleDataForSpotMarket(marketIndex) ? driftClient.getOracleDataForSpotMarket(marketIndex)
: driftClient.getOracleDataForPerpMarket(marketIndex); : driftClient.getMMOracleDataForPerpMarket(marketIndex);
// Get oracle price // Get oracle price
const oraclePrice = oracleData.price ?? ZERO; const oraclePrice = oracleData.price ?? ZERO;