Skip to content

fix: wrap the right amount of sol#432

Merged
guibescos merged 11 commits intomainfrom
fix/user-wsol-bug-2
Mar 18, 2025
Merged

fix: wrap the right amount of sol#432
guibescos merged 11 commits intomainfrom
fix/user-wsol-bug-2

Conversation

@guibescos
Copy link
Copy Markdown
Contributor

@guibescos guibescos commented Mar 17, 2025

There was a bug where we were wrapping the wrong amount of SOL when searcher_specfied, fee_token == "user" and the user_token is wrapped SOL

@vercel
Copy link
Copy Markdown

vercel Bot commented Mar 17, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

1 Skipped Deployment
Name Status Preview Comments Updated (UTC)
swap-staging ⬜️ Ignored (Inspect) Visit Preview Mar 18, 2025 3:42pm

@guibescos guibescos changed the title Fix/user wsol bug 2 fix: wrap the right amount of sol Mar 17, 2025
Comment thread sdk/rust/src/svm.rs Outdated
Comment thread sdk/js/src/svm.ts Outdated
Comment thread sdk/rust/src/svm.rs Outdated
Comment thread sdk/js/src/svm.ts
.add(denominator.sub(new anchor.BN(1)))
.div(denominator);
}
const bidAmountIncludingFees = getBidAmountIncludingFees(
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I renamed the variable because I don't like mutating the argument bidAmount like we did previously

@guibescos guibescos merged commit e8263f0 into main Mar 18, 2025
@guibescos guibescos deleted the fix/user-wsol-bug-2 branch March 18, 2025 16:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants