onRegStateChanged method

void onRegStateChanged(
  1. int accId,
  2. RegState state,
  3. String response
)

Handles registtation state changes when received response from server

Implementation

void onRegStateChanged(int accId, RegState state, String response) {
  _logs?.print('onRegStateChanged accId:$accId resp:\'$response\' ${state.toString()}');

  AccountModel? acc = _findAccount(accId);
  if(acc == null) return;

  acc.regText = response;
  acc.regState = state;

  notifyListeners();
}