saveAccount method

Future<void> saveAccount(
  1. String account, {
  2. String? password,
})

Implementation

Future<void> saveAccount(String account, {String? password}) async {
  this.account = account;
  this.password = password;
  var sp = await SharedPreferences.getInstance();
  await sp.setString(SP_ACCOUNT, account);
  await sp.setString(SP_PASSWORD, password.mxText);
}