aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorMark Felder <feld@FreeBSD.org>2020-06-22 17:39:02 -0500
committerMark Felder <feld@FreeBSD.org>2020-06-22 17:39:02 -0500
commitdf5e048cbb7d349b34203ccba49a8f646e4d93a3 (patch)
tree99b70b3b4d7b51d8bb8c0596737ad30ef6c2b57e /lib
parentbf8310f3802c46e6305fcb3832bca297582990d9 (diff)
downloadpleroma-df5e048cbb7d349b34203ccba49a8f646e4d93a3.tar.gz
Do not need a function to provide fallback value with default defined in config.exs
Diffstat (limited to 'lib')
-rw-r--r--lib/pleroma/web/mastodon_api/views/instance_view.ex7
1 files changed, 1 insertions, 6 deletions
diff --git a/lib/pleroma/web/mastodon_api/views/instance_view.ex b/lib/pleroma/web/mastodon_api/views/instance_view.ex
index c498fe632..c6b54e570 100644
--- a/lib/pleroma/web/mastodon_api/views/instance_view.ex
+++ b/lib/pleroma/web/mastodon_api/views/instance_view.ex
@@ -23,7 +23,7 @@ defmodule Pleroma.Web.MastodonAPI.InstanceView do
streaming_api: Pleroma.Web.Endpoint.websocket_url()
},
stats: Pleroma.Stats.get_stats(),
- thumbnail: instance_thumbnail(),
+ thumbnail: Keyword.get(instance, :instance_thumbnail),
languages: ["en"],
registrations: Keyword.get(instance, :registrations_open),
# Extra (not present in Mastodon):
@@ -88,9 +88,4 @@ defmodule Pleroma.Web.MastodonAPI.InstanceView do
end
|> Map.put(:enabled, Config.get([:instance, :federating]))
end
-
- defp instance_thumbnail do
- Pleroma.Config.get([:instance, :instance_thumbnail]) ||
- "#{Pleroma.Web.base_url()}/instance/thumbnail.jpeg"
- end
end