Commit 713815df authored by Dmitriy Zaporozhets's avatar Dmitriy Zaporozhets

Skip git hooks if oldrev or newrev is nil

Signed-off-by: default avatarDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
parent 67e942cc
......@@ -58,6 +58,8 @@ module Gitlab
def pass_git_hooks?(user, project, ref, oldrev, newrev)
return true unless project.git_hook
return true unless newrev && oldrev
git_hook = project.git_hook
# Prevent tag removal
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment