diff options
author | Fire Demon <firedemon@creature.cafe> | 2020-08-20 06:23:13 -0500 |
---|---|---|
committer | Fire Demon <firedemon@creature.cafe> | 2020-08-30 05:45:19 -0500 |
commit | 4d08871722a9186f0c82c41c6a465982f80c06b2 (patch) | |
tree | ed5b66d3804308b27dbb1b7eba3468e8254eb05b /app | |
parent | 14a11eaf3857be65a8a68d74d274fefe1355a529 (diff) |
[Bug] Do not directly merge frozen options hash
Diffstat (limited to 'app')
-rw-r--r-- | app/services/fetch_remote_status_service.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/app/services/fetch_remote_status_service.rb b/app/services/fetch_remote_status_service.rb index 19b2a28c8..4f98b51f6 100644 --- a/app/services/fetch_remote_status_service.rb +++ b/app/services/fetch_remote_status_service.rb @@ -12,9 +12,9 @@ class FetchRemoteStatusService < BaseService resource_options = { prefetched_body: prefetched_body } end - resource_options ||= {} - resource_options[:on_behalf_of] = on_behalf_of + return if resource_url.blank? - ActivityPub::FetchRemoteStatusService.new.call(resource_url, **resource_options) unless resource_url.nil? + resource_options ||= {} + ActivityPub::FetchRemoteStatusService.new.call(resource_url, **resource_options.merge({ on_behalf_of: on_behalf_of })) end end |