Use "repeated" instead of "retweeted" for repeated statuses in Twitter API
authorFrancis Dinh <archaeme@biribiri.dev>
Thu, 9 May 2019 23:48:41 +0000 (19:48 -0400)
committerFrancis Dinh <archaeme@biribiri.dev>
Thu, 9 May 2019 23:58:34 +0000 (19:58 -0400)
This makes it consistent with the language used in Pleroma FE (at least
in English).

Resolves https://git.pleroma.social/pleroma/pleroma-fe/issues/533

lib/pleroma/web/twitter_api/views/activity_view.ex
test/web/twitter_api/views/activity_view_test.exs

index c64152da8f844cde4f5e70dfdee7fba3bb7af7bf..d084ad7344778199a0968e374573f7c76da857e0 100644 (file)
@@ -170,7 +170,7 @@ defmodule Pleroma.Web.TwitterAPI.ActivityView do
     created_at = activity.data["published"] |> Utils.date_to_asctime()
     announced_activity = Activity.get_create_by_object_ap_id(activity.data["object"])
 
-    text = "#{user.nickname} retweeted a status."
+    text = "#{user.nickname} repeated a status."
 
     retweeted_status = render("activity.json", Map.merge(opts, %{activity: announced_activity}))
 
index 1aa533b48720a6bf705190fa9597cd216178b3ab..43bd77f782965db1bb5a16424c5f4e5140a976e8 100644 (file)
@@ -295,8 +295,8 @@ defmodule Pleroma.Web.TwitterAPI.ActivityViewTest do
       "id" => announce.id,
       "is_local" => true,
       "is_post_verb" => false,
-      "statusnet_html" => "shp retweeted a status.",
-      "text" => "shp retweeted a status.",
+      "statusnet_html" => "shp repeated a status.",
+      "text" => "shp repeated a status.",
       "uri" => "tag:#{announce.data["id"]}:objectType=note",
       "user" => UserView.render("show.json", user: other_user),
       "retweeted_status" => ActivityView.render("activity.json", activity: activity),