db: add back xorm tag for `AccessToken.UserID` (#7032)

pull/7035/head
Joe Chen 2022-06-08 14:47:15 +08:00 committed by GitHub
parent fe1d07f29c
commit 0918d8758b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -43,7 +43,7 @@ var AccessTokens AccessTokensStore
// AccessToken is a personal access token.
type AccessToken struct {
ID int64
UserID int64 `gorm:"column:uid;index"`
UserID int64 `xorm:"uid" gorm:"column:uid;index"`
Name string
Sha1 string `gorm:"type:VARCHAR(40);unique"`
SHA256 string `gorm:"type:VARCHAR(64);unique;not null"`