debianize-mobilizon/lib/eventos_web/views/session_view.ex

8 lines
208 B
Elixir
Raw Normal View History

2017-12-09 14:58:37 +01:00
defmodule EventosWeb.SessionView do
use EventosWeb, :view
def render("token.json", %{token: token, user: user}) do
%{token: token, user: render_one(user, EventosWeb.UserView, "user.json")}
2017-12-09 14:58:37 +01:00
end
end