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

Unified Diff: ios/chrome/browser/passwords/password_controller.mm

Issue 1806333005: Password manager on iOS should understand non-HTML landing pages (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 9 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ios/chrome/browser/passwords/password_controller.mm
diff --git a/ios/chrome/browser/passwords/password_controller.mm b/ios/chrome/browser/passwords/password_controller.mm
index 1938757d5af90ad507bb7f9f11041de8b2e5c704..b62751e6912dc48185e64ceef3f0e003e9b49350 100644
--- a/ios/chrome/browser/passwords/password_controller.mm
+++ b/ios/chrome/browser/passwords/password_controller.mm
@@ -339,13 +339,19 @@ bool GetPageURLAndCheckTrustLevel(web::WebState* web_state, GURL* page_url) {
if (!GetPageURLAndCheckTrustLevel(webState, &pageURL))
return;
- if (!web::UrlHasWebScheme(pageURL) || !webState->ContentIsHTML())
+ if (!web::UrlHasWebScheme(pageURL))
return;
// Notify the password manager that the page loaded so it can clear its own
// per-page state.
passwordManager_->DidNavigateMainFrame();
+ if (!webState->ContentIsHTML()) {
+ // If the current page is not HTML, it does not contain any HTML forms.
+ [self
+ didFinishPasswordFormExtraction:std::vector<autofill::PasswordForm>()];
+ }
+
// Read all password forms from the page and send them to the password
// manager.
base::WeakNSObject<PasswordController> weakSelf(self);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698