#3459 code quality improvement

This commit is contained in:
Unknwon 2016-08-29 20:00:06 -07:00
parent 92fb30c526
commit 28cf0e6aaa
10 changed files with 991 additions and 763 deletions

View file

@ -50,7 +50,7 @@ func CreateLabel(ctx *context.APIContext, form api.CreateLabelOption) {
Color: form.Color,
RepoID: ctx.Repo.Repository.ID,
}
if err := models.NewLabel(label); err != nil {
if err := models.NewLabels(label); err != nil {
ctx.Error(500, "NewLabel", err)
return
}