diff options
author | Mark Felder <feld@FreeBSD.org> | 2019-01-17 15:48:14 +0000 |
---|---|---|
committer | Mark Felder <feld@FreeBSD.org> | 2019-01-17 15:48:14 +0000 |
commit | 8c368d42a20ea21d5d382838843ca1c57a86e882 (patch) | |
tree | 4fcab7eb4d47f0c49516768b3d1e2a5d7fe84580 /lib | |
parent | ce2efd1ee25d6e06c4bc5c0d97aad7b84c7c6874 (diff) | |
download | pleroma-8c368d42a20ea21d5d382838843ca1c57a86e882.tar.gz |
Make attachment links configurable
Thanks @href!
Diffstat (limited to 'lib')
-rw-r--r-- | lib/pleroma/web/common_api/common_api.ex | 2 | ||||
-rw-r--r-- | lib/pleroma/web/mastodon_api/mastodon_api_controller.ex | 1 |
2 files changed, 1 insertions, 2 deletions
diff --git a/lib/pleroma/web/common_api/common_api.ex b/lib/pleroma/web/common_api/common_api.ex index 2902905fd..7d2ac3b0f 100644 --- a/lib/pleroma/web/common_api/common_api.ex +++ b/lib/pleroma/web/common_api/common_api.ex @@ -103,7 +103,7 @@ defmodule Pleroma.Web.CommonAPI do attachments, tags, get_content_type(data["content_type"]), - Enum.member?([true, "true"], data["no_attachment_links"]) + Enum.member?([true, "true"], Map.get(data, "no_attachment_links", Pleroma.Config.get([:instance, :no_attachment_links], true))) ), context <- make_context(inReplyTo), cw <- data["spoiler_text"], diff --git a/lib/pleroma/web/mastodon_api/mastodon_api_controller.ex b/lib/pleroma/web/mastodon_api/mastodon_api_controller.ex index a8fe9d708..daad89185 100644 --- a/lib/pleroma/web/mastodon_api/mastodon_api_controller.ex +++ b/lib/pleroma/web/mastodon_api/mastodon_api_controller.ex @@ -341,7 +341,6 @@ defmodule Pleroma.Web.MastodonAPI.MastodonAPIController do params = params |> Map.put("in_reply_to_status_id", params["in_reply_to_id"]) - |> Map.put("no_attachment_links", true) idempotency_key = case get_req_header(conn, "idempotency-key") do |