From 3f9708edc4cd799afb68000adc35036dd8b8faa5 Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Fri, 23 Sep 2016 20:23:26 +0200 Subject: Change output of api/accounts/:id/follow and unfollow to return relationship Track relationship in redux state. Display follow/unfollow and following-back information on account view (unstyled) --- app/views/api/accounts/relationship.rabl | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 app/views/api/accounts/relationship.rabl (limited to 'app/views/api/accounts/relationship.rabl') diff --git a/app/views/api/accounts/relationship.rabl b/app/views/api/accounts/relationship.rabl new file mode 100644 index 000000000..3e5bf882c --- /dev/null +++ b/app/views/api/accounts/relationship.rabl @@ -0,0 +1,5 @@ +object @account +attribute :id +node(:following) { |account| @following[account.id] || false } +node(:followed_by) { |account| @followed_by[account.id] || false } +node(:blocking) { |account| @blocking[account.id] || false } -- cgit