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
[Identity][CardScan] Move callback from present to creation #4778
Merged
Conversation
This file contains 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
ccen-stripe
commented
Mar 26, 2022
/** | ||
* Callback to notify when scanning finishes and a result is available. | ||
*/ | ||
fun interface CardScanResultCallback { |
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 added to ease Java integration. There is a similar callback for payment at PaymentResultCallback
Diffuse output:
|
awush-stripe
previously approved these changes
Mar 26, 2022
awush-stripe
previously approved these changes
Mar 28, 2022
awush-stripe
force-pushed
the
moveCallback
branch
from
March 29, 2022 21:53
4c02f7a
to
9b7d52f
Compare
ccen-stripe
force-pushed
the
moveCallback
branch
from
March 30, 2022 00:32
9b7d52f
to
1995663
Compare
ccen-stripe
force-pushed
the
moveCallback
branch
from
March 30, 2022 00:33
1995663
to
d297277
Compare
awush-stripe
approved these changes
Mar 30, 2022
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.
Summary
The result callback needs to be registered during creation so that they gets re-registered when hosting activity is recreated.
Please see this internal ticket for more details
Note: this is a breaking API change and would require a major version bump
Motivation
Recovers Identity/CardScan's state when hosting activity is destroyed.
Testing
Screenshots
Changelog
CardImageVerificationSheet
- removed the callback frompresent
tocreate
, wrapping it inside aCardImageVerificationResultCallback
object