Fake 2.4.0 API
authorHaelwenn (lanodan) Monnier <contact@hacktivis.me>
Mon, 4 Jun 2018 15:44:08 +0000 (17:44 +0200)
committerHaelwenn (lanodan) Monnier <contact@hacktivis.me>
Sat, 23 Jun 2018 14:12:57 +0000 (16:12 +0200)
lib/pleroma/web/mastodon_api/mastodon_api_controller.ex
lib/pleroma/web/mastodon_api/views/account_view.ex
lib/pleroma/web/router.ex
test/web/mastodon_api/account_view_test.exs

index 8a8d1e0507699c3ad1111fd12d7407a1c6dd5835..a42f341c20da936d66be896b48ee0e3183fd5b36 100644 (file)
@@ -812,6 +812,7 @@ defmodule Pleroma.Web.MastodonAPI.MastodonAPIController do
             boost_modal: false,
             delete_modal: true,
             auto_play_gif: false,
+            display_sensitive_media: false,
             reduce_motion: false
           },
           compose: %{
index 9db683f44b7662b86af344cccc8027a3f570bb50..f33d615cfd1057bfbb6e71c8590d1ca3cafe7794 100644 (file)
@@ -30,6 +30,8 @@ defmodule Pleroma.Web.MastodonAPI.AccountView do
       avatar_static: image,
       header: header,
       header_static: header,
+      emojis: [],
+      fields: [],
       source: %{
         note: "",
         privacy: "public",
index 13bd393abcfd0f3ae3a3a861bdfd728b1567d577..929a70f91041f5dbfb4e27451a11cb7c3ff6eb15 100644 (file)
@@ -170,6 +170,8 @@ defmodule Pleroma.Web.Router do
     get("/accounts/:id/following", MastodonAPIController, :following)
     get("/accounts/:id", MastodonAPIController, :user)
 
+    get("/trends", MastodonAPIController, :empty_array)
+
     get("/search", MastodonAPIController, :search)
   end
 
index f7b8d74387c2a1aa108b68c2cc68a9dd521f96f7..b93418b3fbf0293dfc60602a1aaa38d8f5c933e4 100644 (file)
@@ -28,6 +28,8 @@ defmodule Pleroma.Web.MastodonAPI.AccountViewTest do
       avatar_static: "http://localhost:4001/images/avi.png",
       header: "http://localhost:4001/images/banner.png",
       header_static: "http://localhost:4001/images/banner.png",
+      emojis: [],
+      fields: [],
       source: %{
         note: "",
         privacy: "public",