mirror of
https://github.com/cuigh/swirl
synced 2025-06-26 18:16:50 +00:00
Refactor code
This commit is contained in:
@@ -8,6 +8,7 @@ import (
|
||||
"github.com/cuigh/auxo/security/passwd"
|
||||
"github.com/cuigh/swirl/biz"
|
||||
"github.com/cuigh/swirl/misc"
|
||||
"github.com/cuigh/swirl/model"
|
||||
)
|
||||
|
||||
type Authenticator struct {
|
||||
@@ -92,7 +93,7 @@ func ldapRealm(s *misc.Setting, ub biz.UserBiz) RealmFunc {
|
||||
lu = user.(*ldap.User)
|
||||
)
|
||||
if u == nil {
|
||||
id, err = ub.Create(&biz.User{
|
||||
id, err = ub.Create(&model.User{
|
||||
Type: biz.UserTypeLDAP,
|
||||
LoginName: loginName,
|
||||
Name: lu.Name(),
|
||||
|
||||
Reference in New Issue
Block a user