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

8 lines
219 B
Elixir
Raw Normal View History

defmodule EventosWeb.UserSessionView do
use EventosWeb, :view
def render("token.json", %{token: token, user: user}) do
%{token: token, user: render_one(user, EventosWeb.UserView, "user_simple.json")}
end
end