aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/pleroma/web/twitter_api/controllers/util_controller.ex6
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/pleroma/web/twitter_api/controllers/util_controller.ex b/lib/pleroma/web/twitter_api/controllers/util_controller.ex
index 7f301a518..2a1c73111 100644
--- a/lib/pleroma/web/twitter_api/controllers/util_controller.ex
+++ b/lib/pleroma/web/twitter_api/controllers/util_controller.ex
@@ -103,8 +103,10 @@ defmodule Pleroma.Web.TwitterAPI.UtilController do
end
defp is_status?(acct) do
- %URI{path: path} = URI.parse(acct)
- Regex.match?(~r/\/users\/[^\/]+\/statuses\/([0-9]+)$/, path)
+ case ActivityPub.fetch_and_contain_remote_object_from_id(acct) do
+ {:ok, %{"type" => "Note"}} -> true
+ _ -> false
+ end
end
def do_remote_follow(conn, %{