Commit b8348987 authored by siyua's avatar siyua Committed by Commit Bot

[AF Paradise] Reset migration acceptance bit after a migration

If one migration request is finished and the user submits another
migration request in the same tab, the card would be automatically saved.

Reason: The member variable user_accepted_main_migration_dialog_ is not
correctly reset to false after a request is sent. So when next time the
risk data is loaded, a request would be direcly sent to server.

This is a bug for M71 code. Need to merge asap.

Bug: 897998
Change-Id: Ia77cdddc6d80550e0e23ff327f07a5c7279ba15f
Reviewed-on: https://chromium-review.googlesource.com/c/1333122
Commit-Queue: Siyu An <siyua@chromium.org>
Reviewed-by: default avatarSebastien Seguin-Gagnon <sebsg@chromium.org>
Cr-Commit-Position: refs/heads/master@{#607746}
parent fcacbb1a
......@@ -245,6 +245,7 @@ void LocalCardMigrationManager::SendMigrateLocalCardsRequest() {
migration_request_, migratable_credit_cards_,
base::BindOnce(&LocalCardMigrationManager::OnDidMigrateLocalCards,
weak_ptr_factory_.GetWeakPtr()));
user_accepted_main_migration_dialog_ = false;
}
// Pops up a larger, modal dialog showing the local cards to be uploaded. Pass
......@@ -252,7 +253,6 @@ void LocalCardMigrationManager::SendMigrateLocalCardsRequest() {
// OnUserAcceptedMainMigrationDialog(). Can be called when user agrees to
// migration on the intermediate dialog or directly from settings page.
void LocalCardMigrationManager::ShowMainMigrationDialog() {
user_accepted_main_migration_dialog_ = false;
AutofillMetrics::LogLocalCardMigrationPromptMetric(
local_card_migration_origin_, AutofillMetrics::MAIN_DIALOG_SHOWN);
// Pops up a larger, modal dialog showing the local cards to be uploaded.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment