This commit is contained in:
@@ -3,11 +3,9 @@
|
||||
|
||||
package v1_7
|
||||
|
||||
import (
|
||||
"xorm.io/xorm"
|
||||
)
|
||||
import "gitea.dev/models/db"
|
||||
|
||||
func AddMustChangePassword(x *xorm.Engine) error {
|
||||
func AddMustChangePassword(x db.EngineMigration) error {
|
||||
// User see models/user.go
|
||||
type User struct {
|
||||
ID int64 `xorm:"pk autoincr"`
|
||||
|
||||
@@ -3,9 +3,9 @@
|
||||
|
||||
package v1_7
|
||||
|
||||
import "xorm.io/xorm"
|
||||
import "gitea.dev/models/db"
|
||||
|
||||
func AddApprovalWhitelistsToProtectedBranches(x *xorm.Engine) error {
|
||||
func AddApprovalWhitelistsToProtectedBranches(x db.EngineMigration) error {
|
||||
type ProtectedBranch struct {
|
||||
ApprovalsWhitelistUserIDs []int64 `xorm:"JSON TEXT"`
|
||||
ApprovalsWhitelistTeamIDs []int64 `xorm:"JSON TEXT"`
|
||||
|
||||
@@ -4,11 +4,12 @@
|
||||
package v1_7
|
||||
|
||||
import (
|
||||
"gitea.dev/models/db"
|
||||
|
||||
"xorm.io/builder"
|
||||
"xorm.io/xorm"
|
||||
)
|
||||
|
||||
func ClearNonusedData(x *xorm.Engine) error {
|
||||
func ClearNonusedData(x db.EngineMigration) error {
|
||||
condDelete := func(colName string) builder.Cond {
|
||||
return builder.NotIn(colName, builder.Select("id").From("`user`"))
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user