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

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

Issue 2432063003: [Autofill] Offer credit card suggestions for some form action. (Closed)
Patch Set: added a test Created 4 years, 2 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_manager.cc
diff --git a/components/autofill/core/browser/autofill_manager.cc b/components/autofill/core/browser/autofill_manager.cc
index 22072d841c50fd3c71b0133067e85452624f27d8..6896ed6017b93dc4bfb4e9388625db8ddb731bfb 100644
--- a/components/autofill/core/browser/autofill_manager.cc
+++ b/components/autofill/core/browser/autofill_manager.cc
@@ -556,7 +556,8 @@ void AutofillManager::OnQueryFormFieldAutofill(int query_id,
if (!suggestions.empty()) {
bool is_context_secure =
client_->IsContextSecure(form_structure->source_url()) &&
- form_structure->target_url().SchemeIs("https");
+ (!form_structure->target_url().is_valid() ||
+ !form_structure->target_url().SchemeIs("http"));
if (is_filling_credit_card)
AutofillMetrics::LogIsQueriedCreditCardFormSecure(is_context_secure);

Powered by Google App Engine
This is Rietveld 408576698