Commit b82325cb authored by Robert Speicher's avatar Robert Speicher

Merge branch 'fix/find-commit-with-empty-rev' into 'master'

Keep note commit around if commit_id is present

Closes gitaly#1054

See merge request gitlab-org/gitlab-ce!17496
parents 0fc80c54 2cc43aaa
......@@ -253,7 +253,7 @@ class Repository
# branches or tags, but we want to keep some of these commits around, for
# example if they have comments or CI builds.
def keep_around(sha)
return unless sha && commit_by(oid: sha)
return unless sha.present? && commit_by(oid: sha)
return if kept_around?(sha)
......
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