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

Unified Diff: components/autofill/core/browser/autofill_profile.cc

Issue 2075503002: [Autofill] Fix the dedupe of verified profiles. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Don't merge verified profiles Created 4 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: components/autofill/core/browser/autofill_profile.cc
diff --git a/components/autofill/core/browser/autofill_profile.cc b/components/autofill/core/browser/autofill_profile.cc
index 9019bc088f43071ee7a012bc6dc6a9b49ca62d50..ee5111b1d0ca28fcf736ae562e6f753217683a92 100644
--- a/components/autofill/core/browser/autofill_profile.cc
+++ b/components/autofill/core/browser/autofill_profile.cc
@@ -574,6 +574,10 @@ bool AutofillProfile::OverwriteWith(const AutofillProfile& profile,
bool AutofillProfile::SaveAdditionalInfo(const AutofillProfile& profile,
const std::string& app_locale) {
+ // If both profiles are verified, do not merge them.
+ if (IsVerified() && profile.IsVerified())
+ return false;
+
ServerFieldTypeSet field_types, other_field_types;
GetNonEmptyTypes(app_locale, &field_types);
profile.GetNonEmptyTypes(app_locale, &other_field_types);

Powered by Google App Engine
This is Rietveld 408576698