about summary refs log tree commit diff
path: root/app/services/fetch_remote_status_service.rb
diff options
context:
space:
mode:
authorThibG <thib@sitedethib.com>2019-12-19 16:07:21 +0100
committerGitHub <noreply@github.com>2019-12-19 16:07:21 +0100
commitf064cd4fb8057af04f0f1db6a98fc45935811e25 (patch)
tree33375e965ba16e3491f3bc3cd733ff2331a48220 /app/services/fetch_remote_status_service.rb
parent66ab1f83b0d342341181e0c88da83c966391fc0c (diff)
parentdace054c0680b3ac6e0da31f3ffa501cd8840fbf (diff)
Merge pull request #1255 from ThibG/glitch-soc/merge-upstream
Merge upstream changes
Diffstat (limited to 'app/services/fetch_remote_status_service.rb')
-rw-r--r--app/services/fetch_remote_status_service.rb9
1 files changed, 3 insertions, 6 deletions
diff --git a/app/services/fetch_remote_status_service.rb b/app/services/fetch_remote_status_service.rb
index 208dc7809..eafde4d4a 100644
--- a/app/services/fetch_remote_status_service.rb
+++ b/app/services/fetch_remote_status_service.rb
@@ -1,17 +1,14 @@
 # frozen_string_literal: true
 
 class FetchRemoteStatusService < BaseService
-  def call(url, prefetched_body = nil, protocol = :ostatus)
+  def call(url, prefetched_body = nil)
     if prefetched_body.nil?
-      resource_url, resource_options, protocol = FetchResourceService.new.call(url)
+      resource_url, resource_options = FetchResourceService.new.call(url)
     else
       resource_url     = url
       resource_options = { prefetched_body: prefetched_body }
     end
 
-    case protocol
-    when :activitypub
-      ActivityPub::FetchRemoteStatusService.new.call(resource_url, **resource_options)
-    end
+    ActivityPub::FetchRemoteStatusService.new.call(resource_url, **resource_options) unless resource_url.nil?
   end
 end