diff options
author | Lauris BH <lauris@nix.lv> | 2023-03-02 01:44:23 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-03-02 01:44:23 +0200 |
commit | 58b414380371a4419f909491700673d43ae6b4ff (patch) | |
tree | 9d994ac5afecdf2109fe93d9ba97a12c201bd27e /modules/repository/create.go | |
parent | de6c718b46ebd3b7f6362c766eed328044d95ec7 (diff) | |
download | gitea-58b414380371a4419f909491700673d43ae6b4ff.tar.gz gitea-58b414380371a4419f909491700673d43ae6b4ff.zip |
Add loading yaml label template files (#22976)
Extract from #11669 and enhancement to #22585 to support exclusive
scoped labels in label templates
* Move label template functionality to label module
* Fix handling of color codes
* Add Advanced label template
Diffstat (limited to 'modules/repository/create.go')
-rw-r--r-- | modules/repository/create.go | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/modules/repository/create.go b/modules/repository/create.go index 1704ea792c..6a1fa41b6b 100644 --- a/modules/repository/create.go +++ b/modules/repository/create.go @@ -23,6 +23,7 @@ import ( user_model "code.gitea.io/gitea/models/user" "code.gitea.io/gitea/models/webhook" "code.gitea.io/gitea/modules/git" + "code.gitea.io/gitea/modules/label" "code.gitea.io/gitea/modules/log" "code.gitea.io/gitea/modules/setting" api "code.gitea.io/gitea/modules/structs" @@ -189,7 +190,7 @@ func CreateRepository(doer, u *user_model.User, opts CreateRepoOptions) (*repo_m // Check if label template exist if len(opts.IssueLabels) > 0 { - if _, err := GetLabelTemplateFile(opts.IssueLabels); err != nil { + if _, err := label.GetTemplateFile(opts.IssueLabels); err != nil { return nil, err } } |