Display Quote posts in the api features list to allow external clients to enable...
authorfoxing <foxing@noreply.akkoma>
Thu, 9 Mar 2023 20:40:28 +0000 (20:40 +0000)
committerfloatingghost <hannah@coffee-and-dreams.uk>
Thu, 9 Mar 2023 20:40:28 +0000 (20:40 +0000)
Expose quote posting in the api as a feature.

Copies what the quote post PR for pleroma does to allow external clients to enable and disable features based on the feature-set of the instance.

As far as I am aware, akkoma doesn't allow you to disable quote posting, so this doesn't need anything fancy and it's just a hard on switch.

I tried to get one for the bubble tl to work also, but I'm not quite sure how to do it so that it switches off the feature when the bubble tl is disabled. I would argue that it could and ideally should be done as well though.

I also discovered a pretty tame bug in the testing of it, that deleting the DB entry for the bubble tl does not stop the bubble TL from actually working and it will continue to display the panel on the about page, I'll just leave it as a note here.

Reviewed-on: https://akkoma.dev/AkkomaGang/akkoma/pulls/496
Co-authored-by: foxing <foxing@noreply.akkoma>
Co-committed-by: foxing <foxing@noreply.akkoma>
lib/pleroma/web/mastodon_api/views/instance_view.ex

index 4fed1af74de38453eeb7db3d3b9c3e19e074f043..2717da99d950b3c441ee3c7263c30b4ba61959ae 100644 (file)
@@ -65,6 +65,7 @@ defmodule Pleroma.Web.MastodonAPI.InstanceView do
       "shareable_emoji_packs",
       "multifetch",
       "pleroma:api/v1/notifications:include_types_filter",
+      "quote_posting",
       "editing",
       if Config.get([:media_proxy, :enabled]) do
         "media_proxy"