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/ci/config/external/file/project.rb')
-rw-r--r--lib/gitlab/ci/config/external/file/project.rb4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/gitlab/ci/config/external/file/project.rb b/lib/gitlab/ci/config/external/file/project.rb
index 16c5375b8bb..16a6bc8a692 100644
--- a/lib/gitlab/ci/config/external/file/project.rb
+++ b/lib/gitlab/ci/config/external/file/project.rb
@@ -89,7 +89,9 @@ module Gitlab
return if project.nil?
- # with `itself`, we are force-loading the project
+ # We are force-loading the project with the `itself` method
+ # because the `project` variable can be a `BatchLoader` object and we should not
+ # pass a `BatchLoader` object in the `for` method to prevent unwanted behaviors.
BatchLoader.for(project.itself)
.batch(key: context.user) do |projects, loader, args|
projects.uniq.each do |project|