Pools limit concurrent nums

This commit is contained in:
Unknown 2014-03-19 21:05:48 -04:00
parent 601c10309d
commit 6f68620860
8 changed files with 43 additions and 25 deletions

View file

@ -51,8 +51,7 @@ type User struct {
Location string
Website string
IsActive bool
Rands string `xorm:"VARCHAR(10)"`
Expired time.Time
Rands string `xorm:"VARCHAR(10)"`
Created time.Time `xorm:"created"`
Updated time.Time `xorm:"updated"`
}
@ -125,7 +124,6 @@ func RegisterUser(user *User) (*User, error) {
user.LowerName = strings.ToLower(user.Name)
user.Avatar = base.EncodeMd5(user.Email)
user.AvatarEmail = user.Email
user.Expired = time.Now().Add(3 * 24 * time.Hour)
user.Rands = GetUserSalt()
if err = user.EncodePasswd(); err != nil {
return nil, err