Skip to content
Snippets Groups Projects
Commit 0e15270b authored by Riyad Preukschas's avatar Riyad Preukschas
Browse files

Fix crash in gitlab:check while checking hooks

parent d9ca1bce
No related branches found
No related tags found
No related merge requests found
Loading
Loading
@@ -645,7 +645,6 @@ namespace :gitlab do
hook_file = "post-receive"
gitolite_hooks_path = File.join(Gitlab.config.gitolite.hooks_path, "common")
gitolite_hook_file = File.join(gitolite_hooks_path, hook_file)
gitolite_hook_content = File.read(gitolite_hook_file)
gitolite_ssh_user = Gitlab.config.gitolite.ssh_user
 
unless File.exists?(gitolite_hook_file)
Loading
Loading
@@ -653,6 +652,7 @@ namespace :gitlab do
return
end
 
gitolite_hook_content = File.read(gitolite_hook_file)
gitlab_hook_file = Rails.root.join.join("lib", "hooks", hook_file)
gitlab_hook_content = File.read(gitlab_hook_file)
 
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment