summaryrefslogtreecommitdiff
path: root/lib/pleroma/web/mastodon_api/views/filter_view.ex
diff options
context:
space:
mode:
authorlain <lain@soykaf.club>2020-08-28 12:17:19 +0000
committerlain <lain@soykaf.club>2020-08-28 12:17:19 +0000
commit73dd5bdb7dcdf804bdbabcf632671d4de5042ebc (patch)
treeefcb0b8e68f86d067de98a23f40a24c7dab79d2f /lib/pleroma/web/mastodon_api/views/filter_view.ex
parentf891e2b2f1d1daa122b9856e4b660be394d31e34 (diff)
parentb141e35d641e733dffe7bd6a45a5bbcafe586c56 (diff)
Merge branch 'release/2.1.0' into 'stable'v2.1.0
Release/2.1.0 See merge request pleroma/pleroma!2927
Diffstat (limited to 'lib/pleroma/web/mastodon_api/views/filter_view.ex')
-rw-r--r--lib/pleroma/web/mastodon_api/views/filter_view.ex8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/pleroma/web/mastodon_api/views/filter_view.ex b/lib/pleroma/web/mastodon_api/views/filter_view.ex
index 97fd1e83f..c37f624e0 100644
--- a/lib/pleroma/web/mastodon_api/views/filter_view.ex
+++ b/lib/pleroma/web/mastodon_api/views/filter_view.ex
@@ -7,11 +7,11 @@ defmodule Pleroma.Web.MastodonAPI.FilterView do
alias Pleroma.Web.CommonAPI.Utils
alias Pleroma.Web.MastodonAPI.FilterView
- def render("filters.json", %{filters: filters} = opts) do
- render_many(filters, FilterView, "filter.json", opts)
+ def render("index.json", %{filters: filters}) do
+ render_many(filters, FilterView, "show.json")
end
- def render("filter.json", %{filter: filter}) do
+ def render("show.json", %{filter: filter}) do
expires_at =
if filter.expires_at do
Utils.to_masto_date(filter.expires_at)
@@ -25,7 +25,7 @@ defmodule Pleroma.Web.MastodonAPI.FilterView do
context: filter.context,
expires_at: expires_at,
irreversible: filter.hide,
- whole_word: false
+ whole_word: filter.whole_word
}
end
end