mirror of
https://github.com/casdoor/casdoor.git
synced 2025-05-23 02:35:49 +08:00
Fix crash in LDAP's sync: GenerateIdForNewUser()
This commit is contained in:
parent
03a281cb5d
commit
981908b0b6
@ -912,7 +912,7 @@ func (user *User) IsGlobalAdmin() bool {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func GenerateIdForNewUser(application *Application) (string, error) {
|
func GenerateIdForNewUser(application *Application) (string, error) {
|
||||||
if application.GetSignupItemRule("ID") != "Incremental" {
|
if application == nil || application.GetSignupItemRule("ID") != "Incremental" {
|
||||||
return util.GenerateId(), nil
|
return util.GenerateId(), nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user