Merge remote-tracking branch 'remotes/origin/develop' into feature/object-hashtags...
authorIvan Tashkinov <ivantashkinov@gmail.com>
Wed, 13 Jan 2021 19:11:16 +0000 (22:11 +0300)
committerIvan Tashkinov <ivantashkinov@gmail.com>
Wed, 13 Jan 2021 19:11:16 +0000 (22:11 +0300)
20 files changed:
1  2 
lib/mix/tasks/pleroma/database.ex
lib/pleroma/activity.ex
lib/pleroma/activity/ir/topics.ex
lib/pleroma/application.ex
lib/pleroma/config.ex
lib/pleroma/delivery.ex
lib/pleroma/ecto_enums.ex
lib/pleroma/object.ex
lib/pleroma/repo.ex
lib/pleroma/web/activity_pub/activity_pub.ex
lib/pleroma/web/activity_pub/mrf/simple_policy.ex
lib/pleroma/web/activity_pub/transmogrifier.ex
lib/pleroma/web/feed/feed_view.ex
lib/pleroma/web/mastodon_api/views/status_view.ex
test/pleroma/activity/ir/topics_test.exs
test/pleroma/object_test.exs
test/pleroma/web/activity_pub/activity_pub_test.exs
test/pleroma/web/activity_pub/transmogrifier/note_handling_test.exs
test/pleroma/web/common_api_test.exs
test/pleroma/web/mastodon_api/views/status_view_test.exs

Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
index a33959d9fa8c606e4b3b78fe55194cfff89fe12a,108f27ef726b5614537b2322db335601bb6a3263..50bf619a73fb1c9928896e477204037bc4449257
@@@ -37,10 -37,9 +37,10 @@@ defmodule Pleroma.Web.ActivityPub.Trans
        data = File.read!("test/fixtures/kroeg-array-less-hashtag.json") |> Jason.decode!()
  
        {:ok, %Activity{data: data, local: false}} = Transmogrifier.handle_incoming(data)
-       object = Object.normalize(data["object"])
+       object = Object.normalize(data["object"], fetch: false)
  
 -      assert "test" in object.data["tag"]
 +      assert "test" in Object.tags(object)
 +      assert Object.hashtags(object) == ["test"]
      end
  
      test "it cleans up incoming notices which are not really DMs" do
        data = File.read!("test/fixtures/mastodon-post-activity-hashtag.json") |> Jason.decode!()
  
        {:ok, %Activity{data: data, local: false}} = Transmogrifier.handle_incoming(data)
-       object = Object.normalize(data["object"])
+       object = Object.normalize(data["object"], fetch: false)
  
 -      assert Enum.at(object.data["tag"], 2) == "moo"
 +      assert Enum.at(Object.tags(object), 2) == "moo"
 +      assert Object.hashtags(object) == ["moo"]
      end
  
      test "it works for incoming notices with contentMap" do
index 1e98208fb8d996b3268bf0ec7da3de71b9c4a57d,2ece9280663e406fb6c7b29c8bccf09f1c4053b6..209fa86f6cae5c4742ad435442d67d9c33aeed18
@@@ -491,9 -491,9 +491,9 @@@ defmodule Pleroma.Web.CommonAPITest d
      user = insert(:user)
      {:ok, activity} = CommonAPI.post(user, %{status: "#2hu #2HU"})
  
-     object = Object.normalize(activity)
+     object = Object.normalize(activity, fetch: false)
  
 -    assert object.data["tag"] == ["2hu"]
 +    assert Object.tags(object) == ["2hu"]
    end
  
    test "it adds emoji in the object" do