Skip to content

Commit

Permalink
Merge branch 'main' into twn
Browse files Browse the repository at this point in the history
  • Loading branch information
tonisevener authored Nov 30, 2023
2 parents 796c362 + 7badd09 commit 55962b4
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions Wikipedia/Code/UIViewController+DonateHelpers.swift
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,13 @@ import PassKit
@objc extension UIViewController {

func canOfferNativeDonateForm(countryCode: String, currencyCode: String, languageCode: String, bannerID: String?, appVersion: String?) -> Bool {

// Hide native Apple Pay path for users with a CN region setting
// https://phabricator.wikimedia.org/T352180
guard countryCode != "CN" else {
return false
}

return nativeDonateFormViewModel(countryCode: countryCode, currencyCode: currencyCode, languageCode: languageCode, bannerID: bannerID, appVersion: appVersion, loggingDelegate: nil) != nil
}

Expand Down

0 comments on commit 55962b4

Please sign in to comment.