about summary refs log tree commit diff
path: root/app/controllers/api/v1/accounts/pins_controller.rb
diff options
context:
space:
mode:
authormultiple creatures <dev@multiple-creature.party>2020-01-11 02:41:35 -0600
committermultiple creatures <dev@multiple-creature.party>2020-01-11 02:41:35 -0600
commitff67dbed2b2878ba0d8032bdde08e06bc0eead3e (patch)
tree805919a162596e67dc8803f9db7892eefc289ea4 /app/controllers/api/v1/accounts/pins_controller.rb
parentd9a9a18afae94ec0a2160e746265e47d7b639eaf (diff)
pass monsterfork api exposure setting to all serializers + add `MONSTERFORK_API_FORCE_*` env vars to set api compatability modes for clients/apps
Diffstat (limited to 'app/controllers/api/v1/accounts/pins_controller.rb')
-rw-r--r--app/controllers/api/v1/accounts/pins_controller.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/app/controllers/api/v1/accounts/pins_controller.rb b/app/controllers/api/v1/accounts/pins_controller.rb
index 0a0239c42..c37c0d0d0 100644
--- a/app/controllers/api/v1/accounts/pins_controller.rb
+++ b/app/controllers/api/v1/accounts/pins_controller.rb
@@ -11,13 +11,13 @@ class Api::V1::Accounts::PinsController < Api::BaseController
 
   def create
     AccountPin.create!(account: current_account, target_account: @account)
-    render json: @account, serializer: REST::RelationshipSerializer, relationships: relationships_presenter
+    render json: @account, serializer: REST::RelationshipSerializer, relationships: relationships_presenter, monsterfork_api: monsterfork_api
   end
 
   def destroy
     pin = AccountPin.find_by(account: current_account, target_account: @account)
     pin&.destroy!
-    render json: @account, serializer: REST::RelationshipSerializer, relationships: relationships_presenter
+    render json: @account, serializer: REST::RelationshipSerializer, relationships: relationships_presenter, monsterfork_api: monsterfork_api
   end
 
   private