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

Set correct consent action for Link signups #4366

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,8 @@ class PaymentSheetLinkAccount: PaymentSheetLinkAccountInfoProtocol {
// Inline, email-prefilled
case implied_v0_0 = "implied_consent_withspm_mobile_v0_0"

// Clicked button in separate Link sheet
case clicked_button_mobile = "clicked_button_mobile"
Copy link
Collaborator

Choose a reason for hiding this comment

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

Seems like we should version this similar to the other ones? e.g.:
clicked_button_mobile_v0

}

// Dependencies
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -165,8 +165,7 @@ extension PayWithLinkViewController {
linkAccount.signUp(
with: phoneNumber,
legalName: requiresNameCollection ? legalName : nil,
// TODO(link): Was .button, add new consent action
consentAction: .checkbox_v0
consentAction: .clicked_button_mobile
) { [weak self] result in
switch result {
case .success:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -304,7 +304,6 @@ extension PayWithLinkViewController: PayWithLinkCoordinating {
option: .withPaymentDetails(account: linkAccount, paymentDetails: paymentDetails)
)
) { [weak self] result, _ in
// TODO(link): Log confirmation type here
self?.view.isUserInteractionEnabled = true
completion(result)
}
Expand All @@ -317,7 +316,6 @@ extension PayWithLinkViewController: PayWithLinkCoordinating {
elementsSession: context.elementsSession,
with: .applePay
) { [weak self] result, _ in
// TODO(link): Log confirmation type here
switch result {
case .canceled:
// no-op -- we don't dismiss/finish for canceled Apple Pay interactions
Expand Down
Loading