switchAccount method

void switchAccount({
  1. required String pubkey,
})

set logged account

Implementation

void switchAccount({required String pubkey}) {
  if (pubkey.isNotEmpty && accounts.containsKey(pubkey)) {
    _loggedPubkey = pubkey;
  } else {
    throw Exception("unknown account for pubkey");
  }
}