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

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

Issue 2775553004: [WebPayments] Implementing Profile filter and dedupe (Closed)
Patch Set: rebasing Created 3 years, 8 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
« no previous file with comments | « components/autofill/core/browser/form_group.h ('k') | components/payments/README » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/autofill/core/browser/form_group.cc
diff --git a/components/autofill/core/browser/form_group.cc b/components/autofill/core/browser/form_group.cc
index 417f08a9043b10b0fefafe85c51968dbf3b49d3e..1f248ccf94e48d891670182804304930e3fc97d3 100644
--- a/components/autofill/core/browser/form_group.cc
+++ b/components/autofill/core/browser/form_group.cc
@@ -57,4 +57,14 @@ bool FormGroup::SetInfo(const AutofillType& type,
return true;
}
+bool FormGroup::HasInfo(ServerFieldType type) const {
+ return HasInfo(AutofillType(type));
+}
+
+bool FormGroup::HasInfo(const AutofillType& type) const {
+ // Use "en-US" as a placeholder locale. We are only interested in emptiness,
+ // not in the presentation of the string.
+ return !GetInfo(type, "en-US").empty();
+}
+
} // namespace autofill
« no previous file with comments | « components/autofill/core/browser/form_group.h ('k') | components/payments/README » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698