about summary refs log tree commit diff
path: root/app/services/resolve_account_service.rb
diff options
context:
space:
mode:
authorSurinna Curtis <ekiru.0@gmail.com>2018-05-02 05:40:24 -0500
committerEugen Rochko <eugen@zeonfederated.com>2018-05-02 12:40:24 +0200
commitdc786c0cf4467ade8db7d8b17e09f16923bfc1e8 (patch)
tree955931c945e9137b4883571cfd2d23bec1d59397 /app/services/resolve_account_service.rb
parent86efccce2a874d16aa783d989ff4824bcfac40b5 (diff)
Support Actors/Statuses with multiple types (#7305)
* Add equals_or_includes_any? helper in JsonLdHelper

* Support arrays in JSON-LD type fields for actors/tags/objects.

* Spec for resolving accounts with extension types

* Style tweaks for codeclimate
Diffstat (limited to 'app/services/resolve_account_service.rb')
-rw-r--r--app/services/resolve_account_service.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/services/resolve_account_service.rb b/app/services/resolve_account_service.rb
index 8cba88f01..de8d1151d 100644
--- a/app/services/resolve_account_service.rb
+++ b/app/services/resolve_account_service.rb
@@ -189,7 +189,7 @@ class ResolveAccountService < BaseService
     return @actor_json if defined?(@actor_json)
 
     json        = fetch_resource(actor_url, false)
-    @actor_json = supported_context?(json) && ActivityPub::FetchRemoteAccountService::SUPPORTED_TYPES.include?(json['type']) ? json : nil
+    @actor_json = supported_context?(json) && equals_or_includes_any?(json['type'], ActivityPub::FetchRemoteAccountService::SUPPORTED_TYPES) ? json : nil
   end
 
   def atom