[Cashtab] [wallet mgmt improvements p2] Only update wallet when user has changed wallets
Summary:
T2822
Depends on D12841
The settings page needs to update the savedWallets data in state whenever the user has changed wallets. Since all wallets have unique names, wallet.name is the right param to monitor for changes. If you just use wallet, this loop also runs every time the update function in useWallet.js runs.
Test Plan:
npm start
Monitor the dev log for a couple of minutes to ensure that update has run several times
Note the msg User has changed the active wallet in Configure.js only appears when you change active wallets
Reviewers: #bitcoin_abc, emack
Reviewed By: #bitcoin_abc, emack
Subscribers: emack
Differential Revision: https://reviews.bitcoinabc.org/D12842