diff options
author | Eugen Rochko <eugen@zeonfederated.com> | 2017-01-15 14:01:33 +0100 |
---|---|---|
committer | Eugen Rochko <eugen@zeonfederated.com> | 2017-01-15 14:01:33 +0100 |
commit | e9737c2235ec56502e650bd1adad3f32bf85f0ef (patch) | |
tree | ececd729f513fd14998f2be30169973956ef6f59 /app/services | |
parent | ab165547fdf556b10b80898c030d54e20bff50af (diff) |
Fix tests, add applications to eager loading/cache for statuses, fix
application website validation, don't link to app website if website isn't set, also comment out animated boost icon from #464 until it's consistent with non-animated version
Diffstat (limited to 'app/services')
-rw-r--r-- | app/services/post_status_service.rb | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/app/services/post_status_service.rb b/app/services/post_status_service.rb index 86a84f512..af31c923f 100644 --- a/app/services/post_status_service.rb +++ b/app/services/post_status_service.rb @@ -7,10 +7,17 @@ class PostStatusService < BaseService # @param [Status] in_reply_to Optional status to reply to # @param [Hash] options # @option [Boolean] :sensitive + # @option [String] :visibility # @option [Enumerable] :media_ids Optional array of media IDs to attach + # @option [Doorkeeper::Application] :application # @return [Status] def call(account, text, in_reply_to = nil, options = {}) - status = account.statuses.create!(text: text, thread: in_reply_to, sensitive: options[:sensitive], visibility: options[:visibility], application: options[:application]) + status = account.statuses.create!(text: text, + thread: in_reply_to, + sensitive: options[:sensitive], + visibility: options[:visibility], + application: options[:application]) + attach_media(status, options[:media_ids]) process_mentions_service.call(status) process_hashtags_service.call(status) |