tidy: modernize-use-emplace

This commit is contained in:
MarcoFalke
2023-10-04 13:53:40 +02:00
parent 4a5aae9330
commit fa05a726c2
47 changed files with 167 additions and 162 deletions

View File

@@ -4230,7 +4230,7 @@ util::Result<MigrationResult> MigrateLegacyToDescriptor(const std::string& walle
// Remember this wallet's walletdir to remove after unloading
std::vector<fs::path> wallet_dirs;
wallet_dirs.push_back(fs::PathFromString(local_wallet->GetDatabase().Filename()).parent_path());
wallet_dirs.emplace_back(fs::PathFromString(local_wallet->GetDatabase().Filename()).parent_path());
// Unload the wallet locally
assert(local_wallet.use_count() == 1);
@@ -4243,7 +4243,7 @@ util::Result<MigrationResult> MigrateLegacyToDescriptor(const std::string& walle
// Get the directories to remove after unloading
for (std::shared_ptr<CWallet>& w : created_wallets) {
wallet_dirs.push_back(fs::PathFromString(w->GetDatabase().Filename()).parent_path());
wallet_dirs.emplace_back(fs::PathFromString(w->GetDatabase().Filename()).parent_path());
}
// Unload the wallets