Fix handling report from a deactivated user

This commit is contained in:
tusooa 2023-07-02 11:15:34 -04:00
commit 6e4de2383f
No known key found for this signature in database
GPG key ID: 42AEC43D48433C51
3 changed files with 23 additions and 1 deletions

View file

@ -583,7 +583,7 @@ defmodule Pleroma.Web.CommonAPI do
end
def update_report_state(activity_id, state) do
with %Activity{} = activity <- Activity.get_by_id(activity_id) do
with %Activity{} = activity <- Activity.get_by_id(activity_id, filter: []) do
Utils.update_report_state(activity, state)
else
nil -> {:error, :not_found}