From e72acd5e5b2d043fcf0a0182a1eedaed8120c155 Mon Sep 17 00:00:00 2001 From: Lunny Xiao Date: Wed, 2 Nov 2022 16:54:36 +0800 Subject: Split migrations folder (#21549) There are too many files in `models/migrations` folder so that I split them into sub folders. --- models/migrations/v1_17/v213.go | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 models/migrations/v1_17/v213.go (limited to 'models/migrations/v1_17/v213.go') diff --git a/models/migrations/v1_17/v213.go b/models/migrations/v1_17/v213.go new file mode 100644 index 0000000000..7b1b158f9f --- /dev/null +++ b/models/migrations/v1_17/v213.go @@ -0,0 +1,18 @@ +// Copyright 2022 The Gitea Authors. All rights reserved. +// Use of this source code is governed by a MIT-style +// license that can be found in the LICENSE file. + +package v1_17 // nolint + +import ( + "xorm.io/xorm" +) + +func AddAllowMaintainerEdit(x *xorm.Engine) error { + // PullRequest represents relation between pull request and repositories. + type PullRequest struct { + AllowMaintainerEdit bool `xorm:"NOT NULL DEFAULT false"` + } + + return x.Sync2(new(PullRequest)) +} -- cgit v1.2.3