fix(web): populate the reason for "cannot commit to branch" in web editor commit form (#39155)

Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
This commit is contained in:
Nitish-1303
2026-08-29 03:16:58 +05:30
committed by GitHub
parent 60326ca03d
commit e806566b39
12 changed files with 54 additions and 51 deletions
+3 -4
View File
@@ -32,10 +32,9 @@
{{if not .CommitFormOptions.CanCommitToBranch}}
<div class="tw-mt-2">
{{ctx.Locale.Tr "repo.editor.no_commit_to_branch"}}
<ul class="tw-mb-0">
{{if not .CommitFormOptions.UserCanPush}}<li>{{ctx.Locale.Tr "repo.editor.user_no_push_to_branch"}}</li>{{end}}
{{if and .CommitFormOptions.RequireSigned (not .CommitFormOptions.WillSign)}}<li>{{ctx.Locale.Tr "repo.editor.require_signed_commit"}}</li>{{end}}
</ul>
{{if .CommitFormOptions.DenyCommitToBranchReason}}
<ul class="tw-mb-0"><li>{{.CommitFormOptions.DenyCommitToBranchReason}}</li></ul>
{{end}}
</div>
{{end}}
</label>