From 63fd35dffae85ff225c4b3170f2238d838b397dd Mon Sep 17 00:00:00 2001 From: Stephen Paul Weber Date: Wed, 14 Oct 2015 15:47:00 -0500 Subject: [PATCH] Notify replies and repeats This is especially useful for partial federation with remote accounts that are not fully OStatus-enabled but support a pingback protocol. Such accounts will still be notified of replies and repeats of their content even without OStatus support, thus adding to the federated universe. --- plugins/Linkback/LinkbackPlugin.php | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/plugins/Linkback/LinkbackPlugin.php b/plugins/Linkback/LinkbackPlugin.php index 67e9dea7c6..85dcf502c7 100644 --- a/plugins/Linkback/LinkbackPlugin.php +++ b/plugins/Linkback/LinkbackPlugin.php @@ -68,6 +68,14 @@ class LinkbackPlugin extends Plugin // Ignoring results common_replace_urls_callback($c, array($this, 'linkbackUrl')); + + if($notice->isRepeat()) { + $repeat = Notice::getByID($notice->repeat_of); + $this->linkbackUrl($repeat->getUrl()); + } else if(!empty($notice->reply_to)) { + $parent = $notice->getParent(); + $this->linkbackUrl($parent->getUrl()); + } } return true; } -- 2.39.5