diff options
author | ThibG <thib@sitedethib.com> | 2019-10-28 16:25:55 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-10-28 16:25:55 +0100 |
commit | 00793a86bc52e4cb37318e42ea4ceb37a896c727 (patch) | |
tree | 1c49c58aa3c45a4ccc5c513ed0539facaf6cc137 /app/lib/activitypub/activity.rb | |
parent | 18c07738a6b0fa3558863dbb1610695ab6f11b74 (diff) | |
parent | 046cd05a839896ffa3aedb3270c7487f0766bdf9 (diff) |
Merge pull request #1240 from ThibG/glitch-soc/merge-upstream
Merge upstream changes
Diffstat (limited to 'app/lib/activitypub/activity.rb')
-rw-r--r-- | app/lib/activitypub/activity.rb | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/app/lib/activitypub/activity.rb b/app/lib/activitypub/activity.rb index a4a9baaee..5cd48a6ae 100644 --- a/app/lib/activitypub/activity.rb +++ b/app/lib/activitypub/activity.rb @@ -153,6 +153,14 @@ class ActivityPub::Activity fetch_remote_original_status end + def follow_request_from_object + @follow_request ||= FollowRequest.find_by(target_account: @account, uri: object_uri) unless object_uri.nil? + end + + def follow_from_object + @follow ||= Follow.find_by(target_account: @account, uri: object_uri) unless object_uri.nil? + end + def fetch_remote_original_status if object_uri.start_with?('http') return if ActivityPub::TagManager.instance.local_uri?(object_uri) |