reverting pinned posts in filtering
authorAlexander Strizhakov <alex.strizhakov@gmail.com>
Wed, 12 Aug 2020 17:01:21 +0000 (20:01 +0300)
committerAlexander Strizhakov <alex.strizhakov@gmail.com>
Wed, 12 Aug 2020 17:01:21 +0000 (20:01 +0300)
lib/mix/tasks/pleroma/database.ex

index 22a325b477b7574c7c9c8493f174218039925c7f..7d8f00b089b50f6d2dc686a6865a8eec72a38ff1 100644 (file)
@@ -150,10 +150,8 @@ defmodule Mix.Tasks.Pleroma.Database do
     |> Pleroma.RepoStreamer.chunk_stream(100)
     |> Stream.each(fn activities ->
       Enum.each(activities, fn activity ->
-        if not Pleroma.Activity.pinned_by_actor?(activity) do
-          expires_at = Timex.shift(activity.inserted_at, days: days)
-          Pleroma.ActivityExpiration.create(activity, expires_at, false)
-        end
+        expires_at = Timex.shift(activity.inserted_at, days: days)
+        Pleroma.ActivityExpiration.create(activity, expires_at, false)
       end)
     end)
     |> Stream.run()