File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed
services/opencode/src/main/kotlin/com/getcode/opencode/model/financial Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -3,6 +3,7 @@ package com.getcode.opencode.model.financial
33import android.icu.util.ULocale
44import android.os.Parcelable
55import com.flipcash.libs.currency.math.Estimator
6+ import com.flipcash.libs.currency.math.divideWithHighPrecision
67import com.getcode.solana.keys.Mint
78import kotlinx.parcelize.Parcelize
89import kotlinx.serialization.Serializable
@@ -166,11 +167,11 @@ data class Fiat(
166167 return Fiat (
167168 estimation = {
168169 Estimator .sell(
169- amountInQuarks = ( quarks / MULTIPLIER ).toLong() ,
170+ amountInQuarks = quarks,
170171 currentValueInQuarks = token.launchpadMetadata?.coreMintLockedQuarks ? : 0 ,
171172 mintDecimals = 6 , // The desired value here is USDC which is 6
172173 feeBps = 0 ,
173- ).getOrThrow().netAmountToReceive
174+ ).getOrThrow().netAmountToReceive.divideWithHighPrecision( BigDecimal ( MULTIPLIER ))
174175 },
175176 tokenMintDecimals = token.decimals
176177 )
You can’t perform that action at this time.
0 commit comments