debian-mirror-gitlab/app/helpers/branches_helper.rb

12 lines
269 B
Ruby
Raw Normal View History

2018-12-05 23:21:45 +05:30
# frozen_string_literal: true
2014-09-02 18:07:02 +05:30
module BranchesHelper
def project_branches
options_for_select(@project.repository.branch_names, @project.default_branch)
end
2017-08-17 22:00:37 +05:30
def protected_branch?(project, branch)
ProtectedBranch.protected?(project, branch.name)
end
2014-09-02 18:07:02 +05:30
end