mirror of
https://github.com/philomena-dev/philomena.git
synced 2024-12-18 06:57:59 +01:00
11 lines
343 B
Elixir
11 lines
343 B
Elixir
|
defmodule PhilomenaWeb.Image.FavoritesController do
|
||
|
use PhilomenaWeb, :controller
|
||
|
|
||
|
alias Philomena.Images.Image
|
||
|
|
||
|
plug :load_and_authorize_resource, model: Image, id_name: "image_id", persisted: true, preload: [faves: :user]
|
||
|
|
||
|
def index(conn, _params) do
|
||
|
render(conn, "index.html", layout: false, image: conn.assigns.image)
|
||
|
end
|
||
|
end
|