mirror of
https://github.com/casdoor/casdoor.git
synced 2025-07-02 19:40:19 +08:00
feat: skip username restriction for new users coming from OAuth providers. (#1225)
This commit is contained in:
@ -203,12 +203,6 @@ func (c *ApiController) Signup() {
|
||||
}
|
||||
}
|
||||
|
||||
msg = object.CheckUsername(user.Name)
|
||||
if msg != "" {
|
||||
c.ResponseError(msg)
|
||||
return
|
||||
}
|
||||
|
||||
affected := object.AddUser(user)
|
||||
if !affected {
|
||||
c.ResponseError(fmt.Sprintf("Failed to create user, user information is invalid: %s", util.StructToJson(user)))
|
||||
|
Reference in New Issue
Block a user