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 @@ def remote_follow(%{assigns: %{user: user}} = conn, %{"acct" => acct}) 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, %{
diff --git a/test/fixtures/httpoison_mock/emelie.atom b/test/fixtures/httpoison_mock/emelie.atom
new file mode 100644
index 000000000..ddaa1c6ca
--- /dev/null
+++ b/test/fixtures/httpoison_mock/emelie.atom
@@ -0,0 +1,306 @@
+
+
+ https://mastodon.social/users/emelie.atom
+ emelie 🎨
+ 23 / #Sweden / #Artist / #Equestrian / #GameDev
+
+If I ain't spending time with my pets, I'm probably drawing. 🐴 🐱 🐰
+ 2019-02-04T20:22:19Z
+ https://files.mastodon.social/accounts/avatars/000/015/657/original/e7163f98280da1a4.png
+
+ https://mastodon.social/users/emelie
+ http://activitystrea.ms/schema/1.0/person
+ https://mastodon.social/users/emelie
+ emelie
+ emelie@mastodon.social
+ <p>23 / <a href="https://mastodon.social/tags/sweden" class="mention hashtag" rel="tag">#<span>Sweden</span></a> / <a href="https://mastodon.social/tags/artist" class="mention hashtag" rel="tag">#<span>Artist</span></a> / <a href="https://mastodon.social/tags/equestrian" class="mention hashtag" rel="tag">#<span>Equestrian</span></a> / <a href="https://mastodon.social/tags/gamedev" class="mention hashtag" rel="tag">#<span>GameDev</span></a></p><p>If I ain't spending time with my pets, I'm probably drawing. 🐴 🐱 🐰</p>
+
+
+
+ emelie
+ emelie 🎨
+ 23 / #Sweden / #Artist / #Equestrian / #GameDev
+
+If I ain't spending time with my pets, I'm probably drawing. 🐴 🐱 🐰
+ public
+
+
+
+
+
+
+ https://mastodon.social/users/emelie/statuses/101850331907006641
+ 2019-04-01T09:58:50Z
+ 2019-04-01T09:58:50Z
+ New status by emelie
+ http://activitystrea.ms/schema/1.0/note
+ http://activitystrea.ms/schema/1.0/post
+
+ <p>Me: I'm going to make this vital change to my world building in the morning, no way I'll forget this, it's too big of a deal<br />Also me: forgets</p>
+
+ public
+
+
+
+
+
+ https://mastodon.social/users/emelie/statuses/101849626603073336
+ 2019-04-01T06:59:28Z
+ 2019-04-01T06:59:28Z
+ New status by emelie
+ http://activitystrea.ms/schema/1.0/comment
+ http://activitystrea.ms/schema/1.0/post
+
+ <p><span class="h-card"><a href="https://mastodon.social/@Fergant" class="u-url mention">@<span>Fergant</span></a></span> Dom är i stort sett religiös skrift vid det här laget 👏👏</p><p>har dock bara läst svenska översättningen, kanske är dags att jag läser dom på engelska</p>
+
+
+ public
+
+
+
+
+
+
+ https://mastodon.social/users/emelie/statuses/101849580030237068
+ 2019-04-01T06:47:37Z
+ 2019-04-01T06:47:37Z
+ New status by emelie
+ http://activitystrea.ms/schema/1.0/note
+ http://activitystrea.ms/schema/1.0/post
+
+ <p>What's you people's favourite fantasy books? Give me some hot tips 🌞</p>
+
+ public
+
+
+
+
+
+ https://mastodon.social/users/emelie/statuses/101849550599949363
+ 2019-04-01T06:40:08Z
+ 2019-04-01T06:40:08Z
+ New status by emelie
+ http://activitystrea.ms/schema/1.0/note
+ http://activitystrea.ms/schema/1.0/post
+
+ <p>Stick them legs out 💃 <a href="https://mastodon.social/tags/mastocats" class="mention hashtag" rel="tag">#<span>mastocats</span></a></p>
+
+
+
+ public
+
+
+
+
+
+ https://mastodon.social/users/emelie/statuses/101849191533152720
+ 2019-04-01T05:08:49Z
+ 2019-04-01T05:08:49Z
+ New status by emelie
+ http://activitystrea.ms/schema/1.0/note
+ http://activitystrea.ms/schema/1.0/post
+
+ <p>long 🐱 <a href="https://mastodon.social/tags/mastocats" class="mention hashtag" rel="tag">#<span>mastocats</span></a></p>
+
+
+
+ public
+
+
+
+
+
+ https://mastodon.social/users/emelie/statuses/101849165031453009
+ 2019-04-01T05:02:05Z
+ 2019-04-01T05:02:05Z
+ New status by emelie
+ http://activitystrea.ms/schema/1.0/note
+ http://activitystrea.ms/schema/1.0/post
+
+ <p>You gotta take whatever bellyrubbing opportunity you can get before she changes her mind 🦁 <a href="https://mastodon.social/tags/mastocats" class="mention hashtag" rel="tag">#<span>mastocats</span></a></p>
+
+
+
+ public
+
+
+
+
+
+ https://mastodon.social/users/emelie/statuses/101846512530748693
+ 2019-03-31T17:47:31Z
+ 2019-03-31T17:47:31Z
+ New status by emelie
+ http://activitystrea.ms/schema/1.0/note
+ http://activitystrea.ms/schema/1.0/post
+
+ <p>Hello look at this boy having a decent haircut for once <a href="https://mastodon.social/tags/mastohorses" class="mention hashtag" rel="tag">#<span>mastohorses</span></a> <a href="https://mastodon.social/tags/equestrian" class="mention hashtag" rel="tag">#<span>equestrian</span></a></p>
+
+
+
+
+ public
+
+
+
+
+
+ https://mastodon.social/users/emelie/statuses/101846181093805500
+ 2019-03-31T16:23:14Z
+ 2019-03-31T16:23:14Z
+ New status by emelie
+ http://activitystrea.ms/schema/1.0/note
+ http://activitystrea.ms/schema/1.0/post
+
+ <p>Sorry did I disturb the who-is-the-longest-cat competition ? <a href="https://mastodon.social/tags/mastocats" class="mention hashtag" rel="tag">#<span>mastocats</span></a></p>
+
+
+
+ public
+
+
+
+
+
+ https://mastodon.social/users/emelie/statuses/101845897513133849
+ 2019-03-31T15:11:07Z
+ 2019-03-31T15:11:07Z
+ New status by emelie
+ http://activitystrea.ms/schema/1.0/note
+ http://activitystrea.ms/schema/1.0/post
+
+ more earthsea ramblings
+ <p>I'm re-watching Tales from Earthsea for the first time since I read the books, and that Therru doesn't squash Cob like a spider, as Orm Embar did is a wasted opportunity tbh</p>
+
+ public
+
+
+
+
+
+ https://mastodon.social/users/emelie/statuses/101841219051533307
+ 2019-03-30T19:21:19Z
+ 2019-03-30T19:21:19Z
+ New status by emelie
+ http://activitystrea.ms/schema/1.0/note
+ http://activitystrea.ms/schema/1.0/post
+
+ <p>I gave my cats some mackerel and they ate it all in 0.3 seconds, and now they won't stop meowing for more, and I'm tired plz shut up</p>
+
+ public
+
+
+
+
+
+ https://mastodon.social/users/emelie/statuses/101839949762341381
+ 2019-03-30T13:58:31Z
+ 2019-03-30T13:58:31Z
+ New status by emelie
+ http://activitystrea.ms/schema/1.0/comment
+ http://activitystrea.ms/schema/1.0/post
+
+ <p>yet I'm confused about this american dude with a gun, like the heck r ya doin in mah ghibli</p>
+
+ public
+
+
+
+
+
+
+ https://mastodon.social/users/emelie/statuses/101839928677863590
+ 2019-03-30T13:53:09Z
+ 2019-03-30T13:53:09Z
+ New status by emelie
+ http://activitystrea.ms/schema/1.0/note
+ http://activitystrea.ms/schema/1.0/post
+
+ <p>2 hours into Ni no Kuni 2 and I've already sold my soul to this game</p>
+
+ public
+
+
+
+
+
+ https://mastodon.social/users/emelie/statuses/101836329521599438
+ 2019-03-29T22:37:51Z
+ 2019-03-29T22:37:51Z
+ New status by emelie
+ http://activitystrea.ms/schema/1.0/note
+ http://activitystrea.ms/schema/1.0/post
+
+ <p>Pippi Longstocking the original one-punch /man</p>
+
+ public
+
+
+
+
+
+ https://mastodon.social/users/emelie/statuses/101835905282948341
+ 2019-03-29T20:49:57Z
+ 2019-03-29T20:49:57Z
+ New status by emelie
+ http://activitystrea.ms/schema/1.0/note
+ http://activitystrea.ms/schema/1.0/post
+
+ <p>I've had so much wine I thought I had a 3rd brother</p>
+
+ public
+
+
+
+
+
+ https://mastodon.social/users/emelie/statuses/101835878059204660
+ 2019-03-29T20:43:02Z
+ 2019-03-29T20:43:02Z
+ New status by emelie
+ http://activitystrea.ms/schema/1.0/note
+ http://activitystrea.ms/schema/1.0/post
+
+ <p>ååååhhh booi</p>
+
+ public
+
+
+
+
+
+ https://mastodon.social/users/emelie/statuses/101835848050598939
+ 2019-03-29T20:35:24Z
+ 2019-03-29T20:35:24Z
+ New status by emelie
+ http://activitystrea.ms/schema/1.0/comment
+ http://activitystrea.ms/schema/1.0/post
+
+ <p><span class="h-card"><a href="https://thraeryn.net/@thraeryn" class="u-url mention">@<span>thraeryn</span></a></span> if I spent 1 hour and a half watching this monstrosity, I need to</p>
+
+
+ public
+
+
+
+
+
+
+ https://mastodon.social/users/emelie/statuses/101835823138262290
+ 2019-03-29T20:29:04Z
+ 2019-03-29T20:29:04Z
+ New status by emelie
+ http://activitystrea.ms/schema/1.0/comment
+ http://activitystrea.ms/schema/1.0/post
+
+ medical, fluids mention
+ <p><span class="h-card"><a href="https://icosahedron.website/@Trev" class="u-url mention">@<span>Trev</span></a></span> *hugs* ✨</p>
+
+
+ public
+
+
+
+
+
+
diff --git a/test/fixtures/httpoison_mock/emelie.json b/test/fixtures/httpoison_mock/emelie.json
deleted file mode 100644
index 2e164ffdf..000000000
--- a/test/fixtures/httpoison_mock/emelie.json
+++ /dev/null
@@ -1,106 +0,0 @@
-{
- "@context": [
- "https://www.w3.org/ns/activitystreams",
- "https://w3id.org/security/v1",
- {
- "manuallyApprovesFollowers": "as:manuallyApprovesFollowers",
- "toot": "http://joinmastodon.org/ns#",
- "featured": {
- "@id": "toot:featured",
- "@type": "@id"
- },
- "alsoKnownAs": {
- "@id": "as:alsoKnownAs",
- "@type": "@id"
- },
- "movedTo": {
- "@id": "as:movedTo",
- "@type": "@id"
- },
- "schema": "http://schema.org#",
- "PropertyValue": "schema:PropertyValue",
- "value": "schema:value",
- "Hashtag": "as:Hashtag",
- "Emoji": "toot:Emoji",
- "IdentityProof": "toot:IdentityProof",
- "focalPoint": {
- "@container": "@list",
- "@id": "toot:focalPoint"
- }
- }
- ],
- "id": "https://mastodon.social/users/emelie",
- "type": "Person",
- "following": "https://mastodon.social/users/emelie/following",
- "followers": "https://mastodon.social/users/emelie/followers",
- "inbox": "https://mastodon.social/users/emelie/inbox",
- "outbox": "https://mastodon.social/users/emelie/outbox",
- "featured": "https://mastodon.social/users/emelie/collections/featured",
- "preferredUsername": "emelie",
- "name": "emelie 🎨",
- "summary": "