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:
authorGitLab Bot <gitlab-bot@gitlab.com>2020-02-21 00:08:48 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2020-02-21 00:08:48 +0300
commit4d0c47058a89d71d3417ad3bd73781882c8998e8 (patch)
tree808679f68ca8a8511d12779cf618785d6978be81 /app/helpers/projects_helper.rb
parentdf2eda3f14dccb703bd7054d4ddde7803cb1fe7e (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/helpers/projects_helper.rb')
-rw-r--r--app/helpers/projects_helper.rb8
1 files changed, 8 insertions, 0 deletions
diff --git a/app/helpers/projects_helper.rb b/app/helpers/projects_helper.rb
index 023790f7d87..5aff12621b5 100644
--- a/app/helpers/projects_helper.rb
+++ b/app/helpers/projects_helper.rb
@@ -381,6 +381,14 @@ module ProjectsHelper
@project.grafana_integration&.enabled?
end
+ def project_license_name(project)
+ project.repository.license&.name
+ rescue GRPC::Unavailable, GRPC::DeadlineExceeded, Gitlab::Git::CommandError => e
+ Gitlab::ErrorTracking.track_exception(e)
+
+ nil
+ end
+
private
def get_project_nav_tabs(project, current_user)