Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'lib/gitlab/checks/diff_check.rb')
-rw-r--r--lib/gitlab/checks/diff_check.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/gitlab/checks/diff_check.rb b/lib/gitlab/checks/diff_check.rb
index 5de71addd5f..0eb2b4c79ef 100644
--- a/lib/gitlab/checks/diff_check.rb
+++ b/lib/gitlab/checks/diff_check.rb
@@ -46,7 +46,7 @@ module Gitlab
def validate_diff(diff)
validations_for_diff.each do |validation|
if error = validation.call(diff)
- raise ::Gitlab::GitAccess::UnauthorizedError, error
+ raise ::Gitlab::GitAccess::ForbiddenError, error
end
end
end
@@ -77,7 +77,7 @@ module Gitlab
logger.log_timed(LOG_MESSAGES[__method__]) do
path_validations.each do |validation|
if error = validation.call(file_paths)
- raise ::Gitlab::GitAccess::UnauthorizedError, error
+ raise ::Gitlab::GitAccess::ForbiddenError, error
end
end
end