fix: reset signUp identifiers when disabling registration
When registration is disabled, signUp.identifiers must be reset to ["username"] with verify:false. Otherwise Logto enforces email as a mandatory profile field on all users, blocking username-only users (like the admin) from signing in. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -131,6 +131,11 @@ public class EmailConnectorService {
|
|||||||
} else {
|
} else {
|
||||||
logtoClient.updateSignInExperience(Map.of(
|
logtoClient.updateSignInExperience(Map.of(
|
||||||
"signInMode", "SignIn",
|
"signInMode", "SignIn",
|
||||||
|
"signUp", Map.of(
|
||||||
|
"identifiers", List.of("username"),
|
||||||
|
"password", true,
|
||||||
|
"verify", false
|
||||||
|
),
|
||||||
"signIn", Map.of(
|
"signIn", Map.of(
|
||||||
"methods", List.of(
|
"methods", List.of(
|
||||||
Map.of("identifier", "username", "password", true, "verificationCode", false, "isPasswordPrimary", true)
|
Map.of("identifier", "username", "password", true, "verificationCode", false, "isPasswordPrimary", true)
|
||||||
|
|||||||
Reference in New Issue
Block a user