forked from AkkomaGang/akkoma
activitypub: help ecto build a better query for thread mute filtering
using an indexed value in thread_mute table helps ecto build a better query.
This commit is contained in:
parent
130bc8e0d5
commit
5effb2cbca
1 changed files with 1 additions and 1 deletions
|
@ -796,7 +796,7 @@ defp restrict_muted(query, %{"muting_user" => %User{info: info}} = opts) do
|
|||
)
|
||||
|
||||
unless opts["skip_preload"] do
|
||||
from([thread_mute: tm] in query, where: is_nil(tm))
|
||||
from([thread_mute: tm] in query, where: is_nil(tm.user_id))
|
||||
else
|
||||
query
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue