Fix login screen not closing (#3122)

This commit is contained in:
Yashar 2022-07-08 16:01:00 -07:00 committed by GitHub
parent dc810f1d39
commit ab4800c4f2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -310,7 +310,14 @@ public class LoginEncryptionUtils {
.label("geyser.auth.login.form.details.desc")
.input("geyser.auth.login.form.details.email", "account@geysermc.org", "")
.input("geyser.auth.login.form.details.pass", "123456", "")
.closedOrInvalidResultHandler(() -> buildAndShowLoginDetailsWindow(session))
.invalidResultHandler(() -> buildAndShowLoginDetailsWindow(session))
.closedResultHandler(() -> {
if (session.isMicrosoftAccount()) {
buildAndShowMicrosoftAuthenticationWindow(session);
} else {
buildAndShowLoginWindow(session);
}
})
.validResultHandler((response) -> session.authenticate(response.next(), response.next())));
}