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
path: root/lib
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2022-10-14 00:10:36 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2022-10-14 00:10:36 +0300
commit9f4c898b9d7243343ab321227e9cfbfa8babedfe (patch)
tree9a9bec8abe52a03c62b31447be6c80647fb2b24a /lib
parentb1928c08f1642be0f66f6fa2587177b95a1cedc1 (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'lib')
-rw-r--r--lib/tasks/gitlab/usage_data.rake6
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/tasks/gitlab/usage_data.rake b/lib/tasks/gitlab/usage_data.rake
index 822df83ede5..159b70cd673 100644
--- a/lib/tasks/gitlab/usage_data.rake
+++ b/lib/tasks/gitlab/usage_data.rake
@@ -72,11 +72,13 @@ namespace :gitlab do
# Events for templates included in a .gitlab-ci.yml using include:template
def explicit_template_includes
- Gitlab::UsageDataCounters::CiTemplateUniqueCounter.ci_templates("lib/gitlab/ci/templates/").map do |template|
+ Gitlab::UsageDataCounters::CiTemplateUniqueCounter.ci_templates("lib/gitlab/ci/templates/").each_with_object([]) do |template, result|
expanded_template_name = Gitlab::UsageDataCounters::CiTemplateUniqueCounter.expand_template_name(template)
+ next unless expanded_template_name # guard against templates unavailable on FOSS
+
event_name = Gitlab::UsageDataCounters::CiTemplateUniqueCounter.ci_template_event_name(expanded_template_name, :repository_source)
- ci_template_event(event_name)
+ result << ci_template_event(event_name)
end
end