| Index: components/autofill/core/browser/autofill_manager.cc
|
| diff --git a/components/autofill/core/browser/autofill_manager.cc b/components/autofill/core/browser/autofill_manager.cc
|
| index 7cda51daaf99ff7885d5cd08847223df93587550..230050832cbd2e6228907a269564e54567ef3f47 100644
|
| --- a/components/autofill/core/browser/autofill_manager.cc
|
| +++ b/components/autofill/core/browser/autofill_manager.cc
|
| @@ -50,6 +50,7 @@
|
| #include "components/autofill/core/browser/phone_number.h"
|
| #include "components/autofill/core/browser/phone_number_i18n.h"
|
| #include "components/autofill/core/browser/popup_item_ids.h"
|
| +#include "components/autofill/core/browser/validation.h"
|
| #include "components/autofill/core/common/autofill_constants.h"
|
| #include "components/autofill/core/common/autofill_data_validation.h"
|
| #include "components/autofill/core/common/autofill_pref_names.h"
|
| @@ -1163,10 +1164,10 @@ void AutofillManager::ImportFormData(const FormStructure& submitted_form) {
|
| // their card. If no CVC is present, do nothing. We could fall back to a
|
| // local save but we believe that sometimes offering upload and sometimes
|
| // offering local save is a confusing user experience.
|
| - int cvc;
|
| for (const auto& field : submitted_form) {
|
| if (field->Type().GetStorableType() == CREDIT_CARD_VERIFICATION_CODE &&
|
| - base::StringToInt(field->value, &cvc)) {
|
| + IsValidCreditCardSecurityCode(field->value,
|
| + upload_request_.card.type())) {
|
| upload_request_.cvc = field->value;
|
| break;
|
| }
|
|
|