checkOtpMessage method
void
checkOtpMessage()
Implementation
void checkOtpMessage() async {
var data = await _webController?.evaluateJavascript(
source:
"(function() { var item = document.getElementById('resend-otp'); return item.innerHTML; })();");
if (data is String) {
if (data != "null" && data.isNotEmpty) {
if (data.toLowerCase().contains("limit exceeded")) {
_aadhaarSdkController.failureCallback(806);
stopOtp();
}
var boolData = await _webController?.evaluateJavascript(
source:
"(function() { var item = document.getElementById('submit-btn'); return item.disabled; })();");
if (boolData is bool) {
if (!boolData) {
otpErrorMessage.value = "";
stopOtp();
} else {
otpErrorMessage.value = data;
}
}
}
}
}