1
0
mirror of https://github.com/wulkanowy/wulkanowy.git synced 2024-09-20 08:09:10 -05:00

Allow special login format in login form (#1258)

This commit is contained in:
Mikołaj Pich 2021-03-28 19:46:56 +02:00 committed by GitHub
parent f5b46707ff
commit a448092008
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -162,7 +162,7 @@ class LoginFormPresenter @Inject constructor(
view?.setErrorEmailRequired() view?.setErrorEmailRequired()
isCorrect = false isCorrect = false
} }
if ("@" in login && "login" !in host && "email" !in host) { if ("@" in login && "||" !in login && "login" !in host && "email" !in host) {
val emailHost = login.substringAfter("@") val emailHost = login.substringAfter("@")
val emailDomain = URL(host).host val emailDomain = URL(host).host
if (emailHost != emailDomain) { if (emailHost != emailDomain) {