cleaner ecto query to handle restrict_unauthenticated for activities
This fix is for this case: config :pleroma, :restrict_unauthenticated, activities: %{local: true, remote: true}
This commit is contained in:
parent
dc4de79d43
commit
e5e76ec445
1 changed files with 1 additions and 2 deletions
|
@ -1222,8 +1222,7 @@ defmodule Pleroma.Web.ActivityPub.ActivityPub do
|
||||||
|
|
||||||
cond do
|
cond do
|
||||||
local and remote ->
|
local and remote ->
|
||||||
# is there a better way to handle this?
|
from(activity in query, where: false)
|
||||||
from(activity in query, where: 1 == 0)
|
|
||||||
|
|
||||||
local ->
|
local ->
|
||||||
from(activity in query, where: activity.local == false)
|
from(activity in query, where: activity.local == false)
|
||||||
|
|
Loading…
Reference in a new issue