try to tighten up local only toot stuff, like... properly (#163)

* try to tighten up local only toot stuff, like... properly

* try to un-break tests
This commit is contained in:
beatrix
2017-10-09 09:56:17 -04:00
committed by GitHub
parent 92a3181dc6
commit f0a2a6c875
4 changed files with 13 additions and 2 deletions

View File

@@ -9,6 +9,8 @@ class StatusPolicy
end
def show?
return false if local_only? && account.nil?
if direct?
owned? || status.mentions.where(account: account).exists?
elsif private?
@@ -45,4 +47,8 @@ class StatusPolicy
def private?
status.private_visibility?
end
def local_only?
status.local_only?
end
end