Merge branch 'feld-varnish' into 'develop'
[akkoma] / lib / pleroma / web / views / error_view.ex
1 defmodule Pleroma.Web.ErrorView do
2 use Pleroma.Web, :view
3
4 def render("404.json", _assigns) do
5 %{errors: %{detail: "Page not found"}}
6 end
7
8 def render("500.json", _assigns) do
9 %{errors: %{detail: "Internal server error"}}
10 end
11
12 # In case no render clause matches or no
13 # template is found, let's render it as 500
14 def template_not_found(_template, assigns) do
15 render("500.json", assigns)
16 end
17 end