Skip to content

Commit

Permalink
add explanation comment to balance management
Browse files Browse the repository at this point in the history
  • Loading branch information
sviderock committed Dec 16, 2024
1 parent e576d26 commit 1dbd98e
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/earn/EarnEnterAmount.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,12 @@ export default function EarnEnterAmount({ route }: Props) {
}
}, [mode])

// Use different balance for the withdrawal flow.
/**
* Use different balance for the withdrawal flow. As described in this discussion
* (https://github.com/valora-inc/wallet/pull/6246#discussion_r1883426564) the intent of this
* is to abstract away the LP token from the user and just display the token they're depositing,
* so we need to convert the LP token balance to deposit and back to LP token when transacting."
*/
const [inputToken, setInputToken] = useState(() => ({
...availableInputTokens[0],
balance: isWithdrawal
Expand Down

0 comments on commit 1dbd98e

Please sign in to comment.