diff --git a/lib/gitlab/git_access.rb b/lib/gitlab/git_access.rb index 6be0ab08a1f6cceb84297409b50520aa9415b8e8..d5690f870e9dd93461270bc3432f0c0823e857b0 100644 --- a/lib/gitlab/git_access.rb +++ b/lib/gitlab/git_access.rb @@ -45,7 +45,7 @@ module Gitlab def download_access_check if deploy_key - true + deploy_key.has_access_to?(project) elsif user user_download_access_check elsif Guest.can?(:download_code, project)