Ostatus doesn't distinguish between activities / objects on create.
authorRoger Braun <roger@rogerbraun.net>
Wed, 26 Apr 2017 08:08:13 +0000 (10:08 +0200)
committerRoger Braun <roger@rogerbraun.net>
Wed, 26 Apr 2017 08:08:13 +0000 (10:08 +0200)
lib/pleroma/web/ostatus/activity_representer.ex
test/web/ostatus/activity_representer_test.exs

index 367212fe142bd662a48057c1451afbcc6ea9c70d..30e695bcc4b35aa43da8f11a48c59c6f5607d5fe 100644 (file)
@@ -15,7 +15,7 @@ defmodule Pleroma.Web.OStatus.ActivityRepresenter do
     [
       {:"activity:object-type", ['http://activitystrea.ms/schema/1.0/note']},
       {:"activity:verb", ['http://activitystrea.ms/schema/1.0/post']},
-      {:id, h.(activity.data["object"]["id"])},
+      {:id, h.(activity.data["id"])},
       {:title, ['New note by #{user.nickname}']},
       {:content, [type: 'html'], h.(activity.data["object"]["content"])},
       {:published, h.(inserted_at)},
index 10f9a9d0bd5ca4bc62a4f7be4a36778adae174ec..6cea9cff0e4658c8d8f06b4d382cbb15acbff7ae 100644 (file)
@@ -18,7 +18,7 @@ defmodule Pleroma.Web.OStatus.ActivityRepresenterTest do
     expected = """
     <activity:object-type>http://activitystrea.ms/schema/1.0/note</activity:object-type>
     <activity:verb>http://activitystrea.ms/schema/1.0/post</activity:verb>
-    <id>#{note_activity.data["object"]["id"]}</id>
+    <id>#{note_activity.data["id"]}</id>
     <title>New note by #{user.nickname}</title>
     <content type="html">#{note_activity.data["object"]["content"]}</content>
     <published>#{inserted_at}</published>