asciinema.org/web/controllers/asciicast_animation_controller.ex
2017-06-12 11:52:50 +02:00

13 lines
332 B
Elixir

defmodule Asciinema.AsciicastAnimationController do
use Asciinema.Web, :controller
alias Asciinema.Asciicasts
def show(conn, %{"id" => id}) do
asciicast = Asciicasts.get_asciicast!(id)
conn
|> put_layout("simple.html")
|> render("show.html", file_url: asciicast_file_download_url(conn, asciicast))
end
end