summaryrefslogtreecommitdiff
path: root/plugins/OStatus
diff options
context:
space:
mode:
authorBrion Vibber <brion@pobox.com>2010-02-17 02:16:03 +0000
committerBrion Vibber <brion@pobox.com>2010-02-17 02:16:03 +0000
commite51e96d7248b281e7d0e59f5a9bdcd4e7e651e82 (patch)
treedaebfb964a48a75320f7342e4dfa5e216dc46960 /plugins/OStatus
parent19b03ef797190076b726ae25842bc3ed502ebef6 (diff)
OStatus: override source link with the source domain and link to original message
Diffstat (limited to 'plugins/OStatus')
-rw-r--r--plugins/OStatus/OStatusPlugin.php13
1 files changed, 13 insertions, 0 deletions
diff --git a/plugins/OStatus/OStatusPlugin.php b/plugins/OStatus/OStatusPlugin.php
index 3b1329d6c..b6c9fa1d4 100644
--- a/plugins/OStatus/OStatusPlugin.php
+++ b/plugins/OStatus/OStatusPlugin.php
@@ -289,4 +289,17 @@ class OStatusPlugin extends Plugin
$action->script(common_path('plugins/OStatus/js/ostatus.js'));
return true;
}
+
+ function onStartNoticeSourceLink($notice, &$name, &$url, &$title)
+ {
+ if ($notice->source == 'ostatus') {
+ $bits = parse_url($notice->uri);
+ $domain = $bits['host'];
+
+ $name = $domain;
+ $url = $notice->uri;
+ $title = sprintf(_m("Sent from %s via OStatus"), $domain);
+ return false;
+ }
+ }
}