From 4745424bd3b7f6e13e86ebf985977ad3268881e3 Mon Sep 17 00:00:00 2001 From: Douwe Maan <douwe@gitlab.com> Date: Tue, 24 Mar 2015 14:12:03 +0100 Subject: [PATCH] Respond with full GitAccess error if user has project read access. --- CHANGELOG | 1 + lib/api/internal.rb | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/CHANGELOG b/CHANGELOG index 25936eb1e1d..4dfa831b4ec 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -31,6 +31,7 @@ v 7.10.0 (unreleased) - Replace commits calendar with faster contribution calendar that includes issues and merge requests - Add inifinite scroll to user page activity - Don't show commit comment button when user is not signed in. + - Make Git-over-SSH errors more descriptive. v 7.9.0 - Send EmailsOnPush email when branch or tag is created or deleted. diff --git a/lib/api/internal.rb b/lib/api/internal.rb index 30bade74cf6..f98a17773e7 100644 --- a/lib/api/internal.rb +++ b/lib/api/internal.rb @@ -50,7 +50,7 @@ module API status = access.check(params[:action], params[:changes]) end - if project && status && status.allowed? + if project && access.can_read_project? status else Gitlab::GitAccessStatus.new(false, 'No such project') -- 2.30.9