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

Refactor WithdrawError::AmountTooLow #939

Merged
merged 1 commit into from
May 11, 2021
Merged

Conversation

sergeyboyko0791
Copy link

I decided to refactor a bit the WithdrawError::AmountTooLow error type when filling out the docs.

  • Rename WithdrawError::AmountIsTooSmall to WithdrawError::AmountTooLow
  • Add the 'threshold' filed to WithdrawError::AmountTooLow
  • Fix error description of TradePreimageRpcError::VolumeTooLow

* Rename 'WithdrawError::AmountIsTooSmall' to 'WithdrawError::AmountTooLow'
* Add the 'threshold' filed to 'WithdrawError::AmountTooLow'
* Fix error description of 'TradePreimageRpcError::VolumeTooLow'
Copy link
Member

@artemii235 artemii235 left a comment

Choose a reason for hiding this comment

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

👍

@sergeyboyko0791
Copy link
Author

Please note I decided to remove the if amount_sat.is_zero() checking as it did for ERC20. The user will be noticed about the zero transfer amount when he receives transaction details.

@artemii235
Copy link
Member

Please note I decided to remove the if amount_sat.is_zero() checking as it did for ERC20. The user will be noticed about the zero transfer amount when he receives transaction details.

Thanks for noting this! I think it's fine as 0 transfer makes very little sense anyway 🙂

@artemii235 artemii235 merged commit 0794b07 into dev May 11, 2021
@artemii235 artemii235 deleted the withdraw-error-hot-fix branch May 11, 2021 14:00
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