about summary refs log tree commit diff
diff options
context:
space:
mode:
authorEugen Rochko <eugen@zeonfederated.com>2017-09-09 02:02:29 +0200
committerGitHub <noreply@github.com>2017-09-09 02:02:29 +0200
commit7ca173be47c8aa5e8bd2b33aac642193ebb673a0 (patch)
treeab5705c26383b6ea98cada68e8844a43e18f00a0
parent1ae5d49a7192ba247429670fec5f4749c8895edf (diff)
Fix #4850 - When visibility missing from API call to toot, fallback to user preference (#4861)
-rw-r--r--app/services/post_status_service.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/app/services/post_status_service.rb b/app/services/post_status_service.rb
index 568f5a9e7..97c55c4b2 100644
--- a/app/services/post_status_service.rb
+++ b/app/services/post_status_service.rb
@@ -27,9 +27,10 @@ class PostStatusService < BaseService
                                         thread: in_reply_to,
                                         sensitive: options[:sensitive],
                                         spoiler_text: options[:spoiler_text] || '',
-                                        visibility: options[:visibility],
+                                        visibility: options[:visibility] || account.user&.setting_default_privacy,
                                         language: detect_language_for(text, account),
                                         application: options[:application])
+
       attach_media(status, media)
     end