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 6a0becb83062ba76039aa7eca7d096a5c9a3a75f..ba29a6364bf75419d9363854b5dfd573f117b2d0 100644 |
--- a/components/autofill/core/browser/autofill_manager.cc |
+++ b/components/autofill/core/browser/autofill_manager.cc |
@@ -1321,15 +1321,22 @@ int AutofillManager::GetProfilesForCreditCardUpload( |
const base::TimeDelta fifteen_minutes = base::TimeDelta::FromMinutes(15); |
int upload_decision_metrics = 0; |
bool has_profile = false; |
+ bool has_modified_profile = false; |
- // First, collect all of the addresses used recently. |
+ // First, collect all of the addresses used or modified recently. |
for (AutofillProfile* profile : personal_data_->GetProfiles()) { |
has_profile = true; |
- if ((now - profile->use_date()) < fifteen_minutes || |
- (now - profile->modification_date()) < fifteen_minutes) { |
+ if ((now - profile->modification_date()) < fifteen_minutes) { |
+ has_modified_profile = true; |
+ candidate_profiles.push_back(*profile); |
+ } else if ((now - profile->use_date()) < fifteen_minutes) { |
candidate_profiles.push_back(*profile); |
} |
} |
+ |
+ AutofillMetrics::LogHasModifiedProfileOnCreditCardFormSubmission( |
+ has_modified_profile); |
+ |
if (candidate_profiles.empty()) { |
upload_decision_metrics |= |
has_profile |