Repository navigation
fix(tip): raise a DM fee floor to the regional minimum - #1599
Merged
Merged
Conversation
minimumToOpenDmWith returned the recipient's converted fee even below minTipAmount. Every tip carries the regional minimum, so a 1000 NGN fee (about $0.76) states a floor the server always denies with "tip amount is below the minimum of 1 USD". A fee under the minimum now falls back to it. The minimum is in the entry currency or is the USD fallback row, and the fee is compared in whichever it is; a fee with no USD rate keeps its own floor.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Stacked on #1597.
minimumToOpenDmWithreturns the recipient's converted fee even when it's underminTipAmount. Every tip carries the regional minimum, so a fee like 1000 NGN (about $0.76) states a floor the server always denies with "tip amount is below the minimum of 1 USD". iOS sees that denial in Bugsnag6a67781.A fee under the minimum now falls back to it. The minimum is in the entry currency or is the USD fallback row, and
isBelowcompares the fee in whichever it is. A fee with no USD rate keeps its own floor and the server stays the authority.TipPaymentDelegateTestadds a $0.50 fee against the $1 minimum and a 1000 NGN fee against the USD fallback row. Both return the fee before this change. The fee floor emits before the presets resolve, so those two tests wait onminTipAmountbefore reading it; the UI picks up the preset on the next emission.The iOS change is code-payments/code-ios-app#891.