changeName method

Future<EthWalletData> changeName(
  1. KeyringEVM keyring,
  2. String name
)

change name of account

Implementation

Future<EthWalletData> changeName(KeyringEVM keyring, String name) async {
  final json = keyring.current.toJson();
  json['name'] = name;
  // update keyPair date in storage
  keyring.store.updateAccount(json);
  return EthWalletData.fromJson(json);
}