pow icon indicating copy to clipboard operation
pow copied to clipboard

Making after confirmation redirections configurable

Open augnustin opened this issue 5 years ago • 1 comments

For now, in https://github.com/augnustin/pow/blob/master/lib/extensions/email_confirmation/phoenix/controllers/confirmation_controller.ex redirection routes are hard coded:

  defp redirect_to(conn) do
    case Pow.Plug.current_user(conn) do
      nil   -> routes(conn).session_path(conn, :new)
      _user -> routes(conn).registration_path(conn, :edit)
    end
  end

Shouldn't those be configurable just like after_sign_in_path etc.?

augnustin avatar Feb 24 '20 14:02 augnustin

I haven't decided how extensions callback routes should work yet #141, and you can still override the routes by customizing path_for/5.

danschultzer avatar Feb 24 '20 15:02 danschultzer