Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: sum total amount leaving the taker's account #73

Merged
merged 1 commit into from
Jan 21, 2025
Merged

Conversation

hzhu
Copy link
Member

@hzhu hzhu commented Jan 21, 2025

Some trades involve a sell tax, which needs to be accounted for. By including both the output amount and the sell tax, we can calculate the total amount leaving the user's wallet. Otherwise, only the tax is shown as the amount leaving the wallet.

resolves #72

Some trades involve a sell tax, which needs to be accounted for. By including
both the output amount and the sell tax, we can calculate the total amount
leaving the user's wallet. Otherwise, only the tax is shown as the amount
leaving the wallet.

resolves #72
@hzhu hzhu self-assigned this Jan 21, 2025
Copy link

codecov bot commented Jan 21, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 100.00%. Comparing base (5de0021) to head (d64f1e2).

Additional details and impacted files
@@            Coverage Diff            @@
##              main       #73   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files            1         1           
  Lines          152       158    +6     
  Branches        31        33    +2     
=========================================
+ Hits           152       158    +6     
Flag Coverage Δ
unittests 100.00% <100.00%> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@hzhu hzhu merged commit 3fa9001 into main Jan 21, 2025
3 checks passed
@hzhu hzhu deleted the fix-total-out-amount branch January 21, 2025 05:07
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.

[bug] tokens with buy/sell tax return wrong amount
1 participant