Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(98)

Unified Diff: ios/chrome/browser/payments/payment_request.mm

Issue 2963163002: [Payment Request] Displays accepted card types (credit, debit, etc) in iOS (Closed)
Patch Set: Created 3 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: ios/chrome/browser/payments/payment_request.mm
diff --git a/ios/chrome/browser/payments/payment_request.mm b/ios/chrome/browser/payments/payment_request.mm
index c40fb13d62ea86e0357e16324c4fb0a8de4e83a4..0bfe0a8d2e3643307238e0cbfe607f3565877434 100644
--- a/ios/chrome/browser/payments/payment_request.mm
+++ b/ios/chrome/browser/payments/payment_request.mm
@@ -11,7 +11,6 @@
#include "base/strings/utf_string_conversions.h"
#include "components/autofill/core/browser/autofill_data_util.h"
#include "components/autofill/core/browser/autofill_profile.h"
-#include "components/autofill/core/browser/credit_card.h"
#include "components/autofill/core/browser/personal_data_manager.h"
#include "components/autofill/core/browser/region_data_loader_impl.h"
#include "components/autofill/core/browser/validation.h"
@@ -286,6 +285,9 @@ void PaymentRequest::PopulateCreditCardCache() {
web_payment_request_.method_data, &supported_card_networks_,
&basic_card_specified_networks_);
+ payments::data_util::ParseSupportedCardTypes(web_payment_request_.method_data,
+ &supported_card_types_set_);
+
const std::vector<autofill::CreditCard*>& credit_cards_to_suggest =
personal_data_manager_->GetCreditCardsToSuggest();
// Return early if the user has no stored credit cards.

Powered by Google App Engine
This is Rietveld 408576698