`Wallet`: `OnDequeue` is unused.
MODIFY
WalletWasabi/Wallets/Wallet.cs
WalletWasabi/Wallets/Wallet.cs
@@ -47,8 +47,6 @@ public class Wallet : BackgroundService
public event EventHandler<ProcessedResult>? WalletRelevantTransactionProcessed;
- public event EventHandler<DequeueResult>? OnDequeue;
-
public static event EventHandler<bool>? InitializingChanged;
public event EventHandler<FilterModel>? NewFilterProcessed;

MODIFY
WalletWasabi/Wallets/WalletManager.cs
WalletWasabi/Wallets/WalletManager.cs
@@ -42,11 +42,6 @@ public class WalletManager
/// </summary>
public event EventHandler<ProcessedResult>? WalletRelevantTransactionProcessed;
- /// <summary>
- /// Triggered if any of the Wallets dequeues one or more coins. The sender of the event will be the Wallet.
- /// </summary>
- public event EventHandler<DequeueResult>? OnDequeue;
-
/// <summary>
/// Triggered if any of the Wallets changes its state. The sender of the event will be the Wallet.
/// </summary>
@@ -245,7 +240,6 @@ public class WalletManager
}
wallet.WalletRelevantTransactionProcessed += TransactionProcessor_WalletRelevantTransactionProcessed;
- wallet.OnDequeue += ChaumianClient_OnDequeue;
wallet.StateChanged += Wallet_StateChanged;
WalletAdded?.Invoke(this, wallet);
@@ -253,11 +247,6 @@ public class WalletManager
public bool WalletExists(HDFingerprint? fingerprint) => GetWallets().Any(x => fingerprint is { } && x.KeyManager.MasterFingerprint == fingerprint);
- private void ChaumianClient_OnDequeue(object? sender, DequeueResult e)
- {
- OnDequeue?.Invoke(sender, e);
- }
-
private void TransactionProcessor_WalletRelevantTransactionProcessed(object? sender, ProcessedResult e)
{
WalletRelevantTransactionProcessed?.Invoke(sender, e);
@@ -298,7 +287,6 @@ public class WalletManager
cancel.ThrowIfCancellationRequested();
wallet.WalletRelevantTransactionProcessed -= TransactionProcessor_WalletRelevantTransactionProcessed;
- wallet.OnDequeue -= ChaumianClient_OnDequeue;
wallet.StateChanged -= Wallet_StateChanged;
lock (Lock)
@@ -314,7 +302,7 @@ public class WalletManager
if (wallet.State >= WalletState.Initialized)
{
var keyManager = wallet.KeyManager;
- string backupWalletFilePath = WalletDirectories.GetWalletFilePaths(Path.GetFileName(keyManager.FilePath)).walletBackupFilePath;
+ string backupWalletFilePath = WalletDirectories.GetWalletFilePaths(Path.GetFileName(keyManager.FilePath)!).walletBackupFilePath;
keyManager.ToFile(backupWalletFilePath);
Logger.LogInfo($"{nameof(wallet.KeyManager)} backup saved to `{backupWalletFilePath}`.");
await wallet.StopAsync(cancel).ConfigureAwait(false);

`Wallet`: `OnDequeue` is unused.