X-Git-Url: https://git.squeep.com/?a=blobdiff_plain;ds=inline;f=lib%2Fpleroma%2Fweb%2Fviews%2Flayout_view.ex;h=ac13cf9626e73390e2091567e8e631270db3751f;hb=f5a315f04cc4e07ff951a2c084525d899291df92;hp=e5183701d6610c2a58ac4f24f678fd208bd11569;hpb=0b54c3d6432dea77542596e34057f8d3fc69ca4c;p=akkoma
diff --git a/lib/pleroma/web/views/layout_view.ex b/lib/pleroma/web/views/layout_view.ex
index e5183701d..ac13cf962 100644
--- a/lib/pleroma/web/views/layout_view.ex
+++ b/lib/pleroma/web/views/layout_view.ex
@@ -1,7 +1,14 @@
# Pleroma: A lightweight social networking server
-# Copyright © 2017-2019 Pleroma Authors
+# Copyright © 2017-2021 Pleroma Authors
# SPDX-License-Identifier: AGPL-3.0-only
defmodule Pleroma.Web.LayoutView do
use Pleroma.Web, :view
+ import Phoenix.HTML
+
+ def render_html(file) do
+ case :httpc.request(Pleroma.Web.Endpoint.url() <> file) do
+ {:ok, {{_, 200, _}, _headers, body}} -> body
+ end
+ end
end