]> cat aescling's git repositories - mastodon.git/commitdiff
Fix undefined local variable (regression from #5114) (#5210)
authorYamagishi Kazutoshi <ykzts@desire.sh>
Wed, 4 Oct 2017 07:51:42 +0000 (16:51 +0900)
committerEugen Rochko <eugen@zeonfederated.com>
Wed, 4 Oct 2017 07:51:42 +0000 (09:51 +0200)
app/services/fetch_atom_service.rb

index bcf516bc3bece1f3ddf608b230f25a5d41af65df..7c54714a2225370093dadf177e5c378fd0e58a20 100644 (file)
@@ -43,7 +43,7 @@ class FetchAtomService < BaseService
     if @response.mime_type == 'application/atom+xml'
       [@url, { prefetched_body: @response.to_s }, :ostatus]
     elsif ['application/activity+json', 'application/ld+json; profile="https://www.w3.org/ns/activitystreams"'].include?(@response.mime_type)
-      json = body_to_json(body)
+      json = body_to_json(@response.to_s)
       if supported_context?(json) && json['type'] == 'Person' && json['inbox'].present?
         [json['id'], { id: true }, :activitypub]
       else