addContact method

Future<EthWalletData> addContact(
  1. KeyringEVM keyring,
  2. Map acc
)

Add a contact.

Implementation

Future<EthWalletData> addContact(KeyringEVM keyring, Map acc) async {
  // save keystore to storage
  await keyring.store.addContact(acc);

  await apiRoot.eth.account.updateAddressIconsMap(keyring, [acc['address']]);

  return EthWalletData.fromJson(acc);
}