diff options
author | Sean McGivern <sean@gitlab.com> | 2016-06-10 18:43:25 +0300 |
---|---|---|
committer | Sean McGivern <sean@gitlab.com> | 2016-06-13 13:05:22 +0300 |
commit | b9977525394ac714e31c1751690c7b993eb8d830 (patch) | |
tree | f6530492505b7a2a9c1c8fbd8c35677ab79dbc08 /app/helpers | |
parent | 747a167a2dce3175102e4aff78504c72178cc5a5 (diff) |
Only show branches for revert / cherry-pick
Tags are immutable, so we can't add a commit to either revert or
cherry-pick another commit to them.
Diffstat (limited to 'app/helpers')
-rw-r--r-- | app/helpers/branches_helper.rb | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/app/helpers/branches_helper.rb b/app/helpers/branches_helper.rb index e39548e17e1..3ee3fc74f0c 100644 --- a/app/helpers/branches_helper.rb +++ b/app/helpers/branches_helper.rb @@ -14,4 +14,8 @@ module BranchesHelper ::Gitlab::GitAccess.new(current_user, project).can_push_to_branch?(branch_name) end + + def project_branches + options_for_select(@project.repository.branch_names, @project.default_branch) + end end |