Add GetWallets method to WalletManager
MODIFY
WalletWasabi.Gui/Controls/WalletExplorer/WalletExplorerViewModel.cs
WalletWasabi.Gui/Controls/WalletExplorer/WalletExplorerViewModel.cs
@@ -152,9 +152,9 @@ namespace WalletWasabi.Gui.Controls.WalletExplorer
private void LoadWallets()
{
- foreach (var wallet in WalletManager.GetKeyManagers())
+ foreach (var wallet in WalletManager.GetWallets())
{
- InsertWallet(new ClosedWalletViewModel(WalletManager.GetWalletByName(wallet.WalletName)));
+ InsertWallet(new ClosedWalletViewModel(wallet));
}
}

MODIFY
WalletWasabi/Wallets/WalletManager.cs
WalletWasabi/Wallets/WalletManager.cs
@@ -112,6 +112,14 @@ namespace WalletWasabi.Wallets
/// <param name="refreshWalletList">Refreshes wallet list from files.</param>
public IEnumerable<KeyManager> GetKeyManagers(bool refreshWalletList = true)
+ {
+ var wallets = GetWallets(refreshWalletList);
+
+ return wallets
+ .Select(x => x.KeyManager);
+ }
+
+ public IEnumerable<Wallet> GetWallets(bool refreshWalletList = true)
{
if (refreshWalletList)
{
@@ -121,7 +129,6 @@ namespace WalletWasabi.Wallets
lock (Lock)
{
return Wallets.Keys
- .Select(x => x.KeyManager)
.ToList();
}
}

Add GetWallets method to WalletManager