Skip to content

Commit 8da23e7

Browse files
committed
Make sure to pull org labels too.
1 parent 817fc88 commit 8da23e7

File tree

2 files changed

+13
-0
lines changed

2 files changed

+13
-0
lines changed

routers/web/org/org_labels.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,7 @@ func UpdateLabel(ctx *context.Context) {
7373

7474
l.Name = form.Title
7575
l.Exclusive = form.Exclusive
76+
l.ExclusiveOrder = form.ExclusiveOrder
7677
l.Description = form.Description
7778
l.Color = form.Color
7879
l.SetArchived(form.IsArchived)

routers/web/repo/issue_list.go

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -468,6 +468,18 @@ func renderExclusiveLabelScopes(ctx *context.Context) {
468468
ctx.ServerError("GetAllRepoLabels", err)
469469
return
470470
}
471+
472+
if ctx.Repo.Owner.IsOrganization() {
473+
orgLabels, err := issues_model.GetLabelsByOrgID(ctx, ctx.Repo.Owner.ID, "", db.ListOptions{})
474+
if err != nil {
475+
ctx.ServerError("GetAllRepoLabels", err)
476+
return
477+
}
478+
479+
labels = append(labels, orgLabels...)
480+
}
481+
482+
// This treats org- and repo-level label scopes equivalently.
471483
scopeSet := make(map[string]bool, 0)
472484
for _, label := range labels {
473485
scope := label.ExclusiveScope()

0 commit comments

Comments
 (0)