-
Notifications
You must be signed in to change notification settings - Fork 472
Issue #10205: Add support for select credit card prompt #10213
Conversation
Codecov Report
@@ Coverage Diff @@
## master #10213 +/- ##
============================================
+ Coverage 73.99% 76.34% +2.35%
+ Complexity 6227 4794 -1433
============================================
Files 833 592 -241
Lines 31694 23078 -8616
Branches 5265 3836 -1429
============================================
- Hits 23452 17620 -5832
+ Misses 5549 3407 -2142
+ Partials 2693 2051 -642
Continue to review full report at Codecov.
|
bce8174
to
4605d37
Compare
This pull request has conflicts when rebasing. Could you fix it @gabrielluong? 🙏 |
95219e0
to
9316743
Compare
*/ | ||
@Parcelize | ||
data class CreditCard( | ||
val guid: String?, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It seems a bit strange to have an identifier that can be null? Would you mind helping me to clarify this part?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is because of GV's Credit Card guid can be nullable. https://mozilla.github.io/geckoview/javadoc/mozilla-central/org/mozilla/geckoview/Autocomplete.CreditCard.html#guid
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That seems odd. Maybe there is a mistake in the API? The other fields are non-null, so a GUID should also be non-null.
...nents/concept/engine/src/main/java/mozilla/components/concept/engine/prompt/PromptRequest.kt
Outdated
Show resolved
Hide resolved
...s/concept/engine/src/test/java/mozilla/components/concept/engine/prompt/PromptRequestTest.kt
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just a couple of nits and one question that doesn't block from landing.
- Implements an override function of `onCreditCardSelect` in `GeckoPromptDelegate` - Adds a new `CreditCard` data class in `concept-engine`. This is a parallel of GV's `Autocomplete.CreditCard`. We can't using the existing `CreditCard` from `concept-storage` since that has encryption dependencies whereas the card number is already decrypted when it reaches GV. - Adds a new `SelectCreditCard` in `PromptRequest`
Fixes #10205
onCreditCardSelect
inGeckoPromptDelegate
CreditCard
data class inconcept-engine
. This is a parallel of GV'sAutocomplete.CreditCard
. We can't using the existingCreditCard
fromconcept-storage
since that has encryption dependencies whereas the card number is already decrypted
when it reaches GV.
SelectCreditCardPrompt
inPromptRequest
Pull Request checklist
After merge