diff options
author | Sean McGivern <sean@gitlab.com> | 2019-04-11 07:45:48 +0000 |
---|---|---|
committer | Sean McGivern <sean@gitlab.com> | 2019-04-11 07:45:48 +0000 |
commit | dd019c2e0b6e292fb55ed264c430eec4a13c0c6b (patch) | |
tree | 285b17b0b62aab22f71e4661e88dfda083de4040 /lib | |
parent | cd770031736419c142990d7474a98b835ac97a92 (diff) | |
parent | 674b926ef4dd48146be7fa8a8c37861b285bbe3b (diff) | |
download | gitlab-ce-dd019c2e0b6e292fb55ed264c430eec4a13c0c6b.tar.gz |
Merge branch 'jc-guard-against-empty-dereferenced_target' into 'master'
Guard against nil dereferenced_target
Closes #60076
See merge request gitlab-org/gitlab-ce!27192
Diffstat (limited to 'lib')
-rw-r--r-- | lib/gitlab/git/repository.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/gitlab/git/repository.rb b/lib/gitlab/git/repository.rb index c33d243330d..a22e3c4b9dd 100644 --- a/lib/gitlab/git/repository.rb +++ b/lib/gitlab/git/repository.rb @@ -466,7 +466,7 @@ module Gitlab @refs_hash = Hash.new { |h, k| h[k] = [] } (tags + branches).each do |ref| - next unless ref.target && ref.name + next unless ref.target && ref.name && ref.dereferenced_target&.id @refs_hash[ref.dereferenced_target.id] << ref.name end |