mirror of
https://github.com/szkolny-eu/szkolny-android.git
synced 2024-11-24 19:04:38 -06:00
[API/Librus] Fix some more captcha errors.
This commit is contained in:
parent
907b75b22d
commit
e02d3e571d
@ -38,14 +38,18 @@ class LibrusLoginMessages(val data: DataLibrus, val onSuccess: () -> Unit) {
|
||||
|
||||
text?.contains("grecaptcha.ready") == true -> {
|
||||
val url = response?.request()?.url()?.toString() ?: run {
|
||||
data.error(TAG, ERROR_LIBRUS_MESSAGES_OTHER, response, text)
|
||||
//data.error(TAG, ERROR_LIBRUS_MESSAGES_OTHER, response, text)
|
||||
data.messagesLoginSuccessful = false
|
||||
onSuccess()
|
||||
return
|
||||
}
|
||||
|
||||
LibrusRecaptchaHelper(data.app, url, text, onSuccess = { newUrl ->
|
||||
loginWithSynergia(newUrl)
|
||||
}, onTimeout = {
|
||||
data.error(TAG, ERROR_LOGIN_LIBRUS_MESSAGES_TIMEOUT, response, text)
|
||||
//data.error(TAG, ERROR_LOGIN_LIBRUS_MESSAGES_TIMEOUT, response, text)
|
||||
data.messagesLoginSuccessful = false
|
||||
onSuccess()
|
||||
})
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user