mirror of
https://codeberg.org/davrot/forgejo.git
synced 2025-05-20 14:00:04 +02:00
Finish log in user
This commit is contained in:
parent
d8b92b4bc9
commit
56a7ab4da5
8 changed files with 104 additions and 58 deletions
|
@ -192,7 +192,7 @@ func GetUserById(id int64) (*User, error) {
|
|||
|
||||
// LoginUserPlain validates user by raw user name and password.
|
||||
func LoginUserPlain(name, passwd string) (*User, error) {
|
||||
user := User{Name: name, Passwd: passwd}
|
||||
user := User{LowerName: strings.ToLower(name), Passwd: passwd}
|
||||
if err := user.EncodePasswd(); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue