Skip to content

Commit

Permalink
Fix error in state migration 14 for unconnected users (uplift to 1.63…
Browse files Browse the repository at this point in the history
….x) (#22302)

Uplift of #22294 (squashed) to release
  • Loading branch information
brave-builds authored Feb 27, 2024
1 parent 68b61c9 commit aead238
Showing 1 changed file with 8 additions and 9 deletions.
17 changes: 8 additions & 9 deletions components/brave_rewards/core/state/state_migration_v14.cc
Original file line number Diff line number Diff line change
Expand Up @@ -36,15 +36,14 @@ void StateMigrationV14::Migrate(ResultCallback callback) {
return;
}

std::move(callback).Run(
base::ranges::any_of(
std::vector{constant::kWalletBitflyer, constant::kWalletGemini,
constant::kWalletUphold, constant::kWalletZebPay},
[this](const std::string& wallet_type) {
return MigrateExternalWallet(wallet_type);
})
? mojom::Result::OK
: mojom::Result::FAILED);
std::vector providers{constant::kWalletBitflyer, constant::kWalletGemini,
constant::kWalletUphold, constant::kWalletZebPay};

for (auto* provider : providers) {
MigrateExternalWallet(provider);
}

std::move(callback).Run(mojom::Result::OK);
}

} // namespace brave_rewards::internal::state

0 comments on commit aead238

Please sign in to comment.