Merge branch 'develop' of ssh.gitgud.io:lambadalambda/pleroma into feature/follow...
authordtluna <dtluna@openmailbox.org>
Fri, 21 Apr 2017 15:36:03 +0000 (18:36 +0300)
committerdtluna <dtluna@openmailbox.org>
Fri, 21 Apr 2017 15:36:03 +0000 (18:36 +0300)
1  2 
lib/pleroma/web/twitter_api/twitter_api.ex
lib/pleroma/web/twitter_api/twitter_api_controller.ex
test/web/twitter_api/twitter_api_test.exs

index 3d6487396d7c9dc6ff002748c83bbe024a9e8bf7,8ea54852dd6f90eb2bb380f9835c4bde1413870c..4d21ce9d36334d2c2f2a08e34a5272b1344efdeb
@@@ -57,8 -57,16 +57,16 @@@ defmodule Pleroma.Web.TwitterAPI.Contro
      end
    end
  
 -  def follow(%{assigns: %{user: user}} = conn, %{ "user_id" => followed_id }) do
 -    case TwitterAPI.follow(user, followed_id) do
+   def mentions_timeline(%{assigns: %{user: user}} = conn, params) do
+     statuses = TwitterAPI.fetch_mentions(user, params)
+     {:ok, json} = Poison.encode(statuses)
+     conn
+     |> json_reply(200, json)
+   end
 +  def follow(%{assigns: %{user: user}} = conn, params) do
 +    case TwitterAPI.follow(user, params) do
        { :ok, user, followed, _activity } ->
          response = followed |> UserRepresenter.to_json(%{for: user})
          conn