Skip to content

Commit

Permalink
don't show project cog in issue sidebar if no permission (#14953)
Browse files Browse the repository at this point in the history
  • Loading branch information
noerw authored Mar 12, 2021
1 parent 91ee3be commit 855a4f4
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion templates/repo/issue/view_content/sidebar.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,9 @@
<div class="ui {{if or (not .HasIssuesOrPullsWritePermission) .Repository.IsArchived}}disabled{{end}} floating jump select-project dropdown">
<span class="text">
<strong>{{.i18n.Tr "repo.issues.new.projects"}}</strong>
{{svg "octicon-gear"}}
{{if and .HasIssuesOrPullsWritePermission (not .Repository.IsArchived)}}
{{svg "octicon-gear"}}
{{end}}
</span>
<div class="menu" data-action="update" data-issue-id="{{$.Issue.ID}}" data-update-url="{{$.RepoLink}}/issues/projects">
<div class="no-select item">{{.i18n.Tr "repo.issues.new.clear_projects"}}</div>
Expand Down

0 comments on commit 855a4f4

Please sign in to comment.