about summary refs log tree commit diff
path: root/app/services
diff options
context:
space:
mode:
authormultiple creatures <dev@multiple-creature.party>2020-02-04 20:25:23 -0600
committermultiple creatures <dev@multiple-creature.party>2020-02-04 20:25:23 -0600
commita08079dc2571fc02b5cede1b0b04a68035ca2692 (patch)
tree491c723d7c43fb33ecb7538004f54d31b680380c /app/services
parentf867348ed6fc180d538f9dd4ef6f6df66b31ab93 (diff)
check for null visibility, possible with delayed self-replies
Diffstat (limited to 'app/services')
-rw-r--r--app/services/post_status_service.rb2
1 files changed, 2 insertions, 0 deletions
diff --git a/app/services/post_status_service.rb b/app/services/post_status_service.rb
index 6718b5a69..274c2c297 100644
--- a/app/services/post_status_service.rb
+++ b/app/services/post_status_service.rb
@@ -121,6 +121,8 @@ class PostStatusService < BaseService
   end
 
   def limit_visibility_to_reply
+    return if @in_reply_to.visibility.nil?
+
     @visibility = @in_reply_to.visibility if @visibility.nil? ||
       VISIBILITY_RANK[@visibility] < VISIBILITY_RANK[@in_reply_to.visibility]
   end