diff options
author | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2013-11-06 18:19:27 +0200 |
---|---|---|
committer | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2013-11-06 18:19:27 +0200 |
commit | 0aa5063851fe2c1386fd07e6898734e0d5c9465c (patch) | |
tree | 1630a8862adf0a0e96f35845255c080987508f7e /lib/gitlab_projects.rb | |
parent | d61bfbbaf91aae45fc4cc3d3084b31f67e6b3214 (diff) | |
download | gitlab-shell-0aa5063851fe2c1386fd07e6898734e0d5c9465c.tar.gz |
Prevent update-head fail if branch not present in refs/head
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
Diffstat (limited to 'lib/gitlab_projects.rb')
-rw-r--r-- | lib/gitlab_projects.rb | 5 |
1 files changed, 0 insertions, 5 deletions
diff --git a/lib/gitlab_projects.rb b/lib/gitlab_projects.rb index 0dd56be..3617bb2 100644 --- a/lib/gitlab_projects.rb +++ b/lib/gitlab_projects.rb @@ -168,11 +168,6 @@ class GitlabProjects return false end - unless File.exists?(File.join(full_path, 'refs/heads', new_head)) - $logger.error "update-head failed: specified branch does not exist in ref/heads." - return false - end - File.open(File.join(full_path, 'HEAD'), 'w') do |f| f.write("ref: refs/heads/#{new_head}") end |