Fix/login button#592
Conversation
Test Results 144 files 144 suites 3m 4s ⏱️ For more details on these failures, see this check. Results for commit 3ebf4f6. |
| val currentUsername = screenState.value.username | ||
| val currentPassword = screenState.value.password | ||
|
|
||
| if (currentUsername.isBlank() && currentPassword.isBlank()) { | ||
| return | ||
| } | ||
|
|
||
| if (currentUsername == lastTriedUsername && currentPassword == lastTriedPassword) { | ||
| return | ||
| } | ||
|
|
||
| lastTriedUsername = currentUsername | ||
| lastTriedPassword = currentPassword | ||
|
|
There was a problem hiding this comment.
why don't you just add these to a validator class, because the current implementation the user will not be able to know what is happening when press on the login button because nothing will happen and we should display an error message or something to tell the user the user name or the password is empty.
There was a problem hiding this comment.
also another question what if the user entered the user name and the password correctly but the request failed for some reason like because bad internet connection in this way he will not be able to try again because of the lastTriedUsername and the lastTriedPassword
so if we want to do that we should set these variables when we only get the wrong credentials error
No description provided.