about summary refs log tree commit diff
path: root/app/serializers/rest
diff options
context:
space:
mode:
authorFire Demon <firedemon@creature.cafe>2020-06-28 18:08:33 -0500
committerFire Demon <firedemon@creature.cafe>2020-08-30 05:41:03 -0500
commitfbbf4ab62cf0cf3ec54cedb4848c4bcdecdf677b (patch)
tree0e5b026630cd34d5403fdfc4caa035338f8c6d80 /app/serializers/rest
parenta93e2cf17efe2c060df7d999a17ab97428cc4b54 (diff)
[Privacy] Do not disclose private allow list domains to nodeinfo and instance endpoints
Diffstat (limited to 'app/serializers/rest')
-rw-r--r--app/serializers/rest/instance_serializer.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/serializers/rest/instance_serializer.rb b/app/serializers/rest/instance_serializer.rb
index 0a13ad9c2..f20d9ef2b 100644
--- a/app/serializers/rest/instance_serializer.rb
+++ b/app/serializers/rest/instance_serializer.rb
@@ -83,7 +83,7 @@ class REST::InstanceSerializer < ActiveModel::Serializer
 
   def federation
     {
-      domain_allows: display_allows? ? DomainAllow.all.map { |a| a.slice(:domain) } : [],
+      domain_allows: display_allows? ? DomainAllow.where(hidden: false).map { |a| a.slice(:domain) } : [],
       domain_blocks: display_blocks? ? DomainBlock.all.map { |b| b.slice(:domain, :severity, :reject_media, :reject_reports, :public_comment) } : [],
     }
   end