handleExceptionAuth method
void
handleExceptionAuth(
- dynamic e, [
- Iwatting? iwatting
])
Implementation
void handleExceptionAuth(dynamic e, [Iwatting? iwatting]) {
iwatting?.hideWatting();
isInProcess = false;
update();
if (kDebugMode) {
print('handleExceptionAuth :$e');
}
if (e.toString().contains('The SMS code has expired')) {
theSmsOTPTimeOut();
} else if (e.toString().contains('Timed out waiting for SMS')) {
theSMSCodeHasExpried();
} else if (e.toString().contains(
'We have blocked all requests from this device due to unusual activity')) {
theBlockRequest();
} else if (e.toString().contains(
'The sms verification code used to create the phone auth credential is invalid')) {
theSMSOTPInValid();
} else {
if (Common.supperAdmin || kDebugMode) {
Get.snackbar(
Message.getMessage('REGISTER_THONG_BAO'),
e.toString(),
snackPosition: SnackPosition.TOP,
duration: const Duration(milliseconds: 10000),
);
}
}
}