@@ -17,19 +17,15 @@ public void Reset()
1717
1818 public void WaitForWalletTxsToClearPool ( MoneroWallet wallet )
1919 {
20- WaitForWalletTxsToClearPool ( [ wallet ] ) ;
21- }
22-
23- public void WaitForWalletTxsToClearPool ( List < MoneroWallet > wallets )
24- {
20+ List < MoneroWallet > wallets = [ wallet ] ;
2521 // get wallet tx hashes
2622 List < string > txHashesWallet = [ ] ;
27- foreach ( MoneroWallet wallet in wallets )
23+ foreach ( MoneroWallet moneroWallet in wallets )
2824 {
29- if ( ! clearedWallets . Contains ( wallet ) )
25+ if ( ! clearedWallets . Contains ( moneroWallet ) )
3026 {
31- wallet . Sync ( ) ;
32- foreach ( MoneroTxWallet tx in wallet . GetTxs ( ) )
27+ moneroWallet . Sync ( ) ;
28+ foreach ( MoneroTxWallet tx in moneroWallet . GetTxs ( ) )
3329 {
3430 string ? txHash = tx . GetHash ( ) ;
3531 if ( txHash == null )
@@ -42,7 +38,7 @@ public void WaitForWalletTxsToClearPool(List<MoneroWallet> wallets)
4238 }
4339 }
4440
45- // loop until all wallet txs clear from pool
41+ // loop until all wallet txs clear from the pool
4642 bool isFirst = true ;
4743 bool miningStarted = false ;
4844 MoneroDaemon daemon = TestUtils . GetDaemonRpc ( ) ;
@@ -76,7 +72,7 @@ public void WaitForWalletTxsToClearPool(List<MoneroWallet> wallets)
7672 break ;
7773 }
7874
79- // if first time waiting, log message and start mining
75+ // if first time waiting, log a message and start mining
8076 if ( isFirst )
8177 {
8278 isFirst = false ;
@@ -90,7 +86,10 @@ public void WaitForWalletTxsToClearPool(List<MoneroWallet> wallets)
9086 StartMining . Start ( ) ;
9187 miningStarted = true ;
9288 }
93- catch ( Exception e ) { } // no problem
89+ catch ( Exception e )
90+ {
91+ // no problem
92+ }
9493 }
9594 }
9695
@@ -106,10 +105,10 @@ public void WaitForWalletTxsToClearPool(List<MoneroWallet> wallets)
106105 }
107106
108107 // sync wallets with the pool
109- foreach ( MoneroWallet wallet in wallets )
108+ foreach ( MoneroWallet moneroWallet in wallets )
110109 {
111- wallet . Sync ( ) ;
112- clearedWallets . Add ( wallet ) ;
110+ moneroWallet . Sync ( ) ;
111+ clearedWallets . Add ( moneroWallet ) ;
113112 }
114113 }
115114}
0 commit comments