When filter on public group events, exclude draft events as well

Signed-off-by: Thomas Citharel <tcit@tcit.fr>
This commit is contained in:
Thomas Citharel 2020-10-22 16:58:18 +02:00
parent 40174090f8
commit d8185660e3
No known key found for this signature in database
GPG key ID: A061B9DDE0CA0773

View file

@ -1704,7 +1704,7 @@ defmodule Mobilizon.Events do
defp event_filter_visibility(query, :public) do defp event_filter_visibility(query, :public) do
query query
|> where(visibility: ^:public) |> where(visibility: ^:public, draft: false)
end end
defp event_filter_begins_on(query, nil, nil), defp event_filter_begins_on(query, nil, nil),