about summary refs log tree commit diff
path: root/app/policies
diff options
context:
space:
mode:
Diffstat (limited to 'app/policies')
-rw-r--r--app/policies/status_policy.rb5
1 files changed, 5 insertions, 0 deletions
diff --git a/app/policies/status_policy.rb b/app/policies/status_policy.rb
index f3d0ffdba..52cfd5050 100644
--- a/app/policies/status_policy.rb
+++ b/app/policies/status_policy.rb
@@ -9,6 +9,7 @@ class StatusPolicy < ApplicationPolicy
 
   def show?
     return false if author.suspended?
+    return false if local_only? && (current_account.nil? || !current_account.local?)
 
     if requires_mention?
       owned? || mention_exists?
@@ -88,4 +89,8 @@ class StatusPolicy < ApplicationPolicy
   def author
     record.account
   end
+
+  def local_only?
+    record.local_only?
+  end
 end