gitea源码

v155.go 400B

12345678910111213141516171819202122
  1. // Copyright 2020 The Gitea Authors. All rights reserved.
  2. // SPDX-License-Identifier: MIT
  3. package v1_14
  4. import (
  5. "fmt"
  6. "xorm.io/xorm"
  7. )
  8. func AddChangedProtectedFilesPullRequestColumn(x *xorm.Engine) error {
  9. type PullRequest struct {
  10. ChangedProtectedFiles []string `xorm:"TEXT JSON"`
  11. }
  12. if err := x.Sync(new(PullRequest)); err != nil {
  13. return fmt.Errorf("Sync: %w", err)
  14. }
  15. return nil
  16. }