Lint
[akkoma] / lib / pleroma / web / preload / status_net.ex
1 # Pleroma: A lightweight social networking server
2 # Copyright © 2017-2020 Pleroma Authors <https://pleroma.social/>
3 # SPDX-License-Identifier: AGPL-3.0-only
4
5 defmodule Pleroma.Web.Preload.Providers.StatusNet do
6 alias Pleroma.Web.Preload.Providers.Provider
7 alias Pleroma.Web.TwitterAPI.UtilView
8
9 @behaviour Provider
10 @config_url :"/api/statusnet/config.json"
11
12 @impl Provider
13 def generate_terms(_params) do
14 %{}
15 |> build_config_tag()
16 end
17
18 defp build_config_tag(acc) do
19 instance = Pleroma.Config.get(:instance)
20 info_data = UtilView.status_net_config(instance)
21
22 Map.put(acc, @config_url, info_data)
23 end
24 end