Merge branch '1993-confirm-users-on-registration' into 'develop'

AccountController: Don't explicitly ask to keep users unconfirmed.

Closes #1993

See merge request pleroma/pleroma!2809
This commit is contained in:
Haelwenn 2020-07-30 20:01:04 +00:00
commit 87fe31fb5c
3 changed files with 85 additions and 14 deletions

View file

@ -100,7 +100,7 @@ defmodule Pleroma.Web.MastodonAPI.AccountController do
def create(%{assigns: %{app: app}, body_params: params} = conn, _params) do
with :ok <- validate_email_param(params),
:ok <- TwitterAPI.validate_captcha(app, params),
{:ok, user} <- TwitterAPI.register_user(params, need_confirmation: true),
{:ok, user} <- TwitterAPI.register_user(params),
{:ok, token} <- Token.create_token(app, user, %{scopes: app.scopes}) do
json(conn, OAuthView.render("token.json", %{user: user, token: token}))
else