Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into fix/activity-expirations-again
This commit is contained in:
commit
0589e9156a
5 changed files with 56 additions and 6 deletions
|
|
@ -130,6 +130,7 @@ defmodule Pleroma.User.Query do
|
|||
defp compose_query({:active, _}, query) do
|
||||
User.restrict_deactivated(query)
|
||||
|> where([u], not is_nil(u.nickname))
|
||||
|> where([u], u.approval_pending == false)
|
||||
end
|
||||
|
||||
defp compose_query({:legacy_active, _}, query) do
|
||||
|
|
|
|||
|
|
@ -18,6 +18,12 @@ defmodule Pleroma.Web.ControllerHelper do
|
|||
|
||||
def truthy_param?(value), do: not falsy_param?(value)
|
||||
|
||||
def json_response(conn, status, _) when status in [204, :no_content] do
|
||||
conn
|
||||
|> put_resp_header("content-type", "application/json")
|
||||
|> send_resp(status, "")
|
||||
end
|
||||
|
||||
def json_response(conn, status, json) do
|
||||
conn
|
||||
|> put_status(status)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue