From 842b41fcf118609a0cdbfe57dab196a54d0b686c Mon Sep 17 00:00:00 2001 From: Anthony Tseng <darkdh@gmail.com> Date: Fri, 26 May 2017 12:36:07 -0700 Subject: [PATCH] Using pending credential instead of submitted form which might contain empty username fix https://github.com/brave/browser-laptop/issues/9028 Auditors: @bridiver, @bbondy --- .../browser/password_manager/brave_password_manager_client.cc | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/brave/browser/password_manager/brave_password_manager_client.cc b/brave/browser/password_manager/brave_password_manager_client.cc index a6ad904d75..9b51b385b2 100644 --- a/brave/browser/password_manager/brave_password_manager_client.cc +++ b/brave/browser/password_manager/brave_password_manager_client.cc @@ -137,8 +137,7 @@ void BravePasswordManagerClient::DidClickNever() { void BravePasswordManagerClient::DidClickUpdate() { if (form_to_save_) { - const autofill::PasswordForm *form = form_to_save_->submitted_form(); - form_to_save_->Update(*form); + form_to_save_->Update(form_to_save_->pending_credentials()); } }