Skip to content

Commit 9879770

Browse files
committed
Merge remote-tracking branch 'remotes/benma/fix-reenable' into frontend-watchonly-individual-watchonly-toggle
2 parents b54eac5 + 52b9f63 commit 9879770

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

backend/accounts.go

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -493,6 +493,7 @@ func copyBool(b *bool) *bool {
493493
// AccountSetWatch sets the account's persisted watch flag to `watch`. Set to `true` if the account
494494
// should be loaded even if its keystore is not connected.
495495
// If `watch` is set to `false`, the account is unloaded and the frontend notified.
496+
// If `watch` is set to `true`, the account is loaded (if the global watchonly flag is enabled) and the frontend notified.
496497
func (backend *Backend) AccountSetWatch(filter func(*config.Account) bool, watch *bool) error {
497498
err := backend.config.ModifyAccountsConfig(func(accountsConfig *config.AccountsConfig) error {
498499
for _, acct := range accountsConfig.Accounts {
@@ -524,10 +525,8 @@ func (backend *Backend) AccountSetWatch(filter func(*config.Account) bool, watch
524525
}
525526
}
526527

527-
if watch == nil || !*watch {
528-
backend.initAccounts(false)
529-
backend.emitAccountsStatusChanged()
530-
}
528+
backend.initAccounts(false)
529+
backend.emitAccountsStatusChanged()
531530
return nil
532531
}
533532

0 commit comments

Comments
 (0)