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 'app/serializers/group_link/project_group_link_entity.rb')
-rw-r--r--app/serializers/group_link/project_group_link_entity.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/serializers/group_link/project_group_link_entity.rb b/app/serializers/group_link/project_group_link_entity.rb
index d246bff1c58..fbad69bf2c5 100644
--- a/app/serializers/group_link/project_group_link_entity.rb
+++ b/app/serializers/group_link/project_group_link_entity.rb
@@ -4,7 +4,7 @@ module GroupLink
class ProjectGroupLinkEntity < GroupLink::GroupLinkEntity
include RequestAwareEntity
- expose :source do |group_link|
+ expose :source, if: ->(group_link) { can_read_shared_group?(group_link) } do |group_link|
ProjectEntity.represent(group_link.shared_from, only: [:id, :full_name])
end