From 536c037bfa6a04a2a08db94330c9a12fe22cd6cb Mon Sep 17 00:00:00 2001 From: Brett Profitt Date: Tue, 21 Feb 2012 22:53:22 -0800 Subject: Fixes #4335. Cleaned up the notifications for new content. --- mod/bookmarks/start.php | 24 +++++++++--------------- 1 file changed, 9 insertions(+), 15 deletions(-) (limited to 'mod/bookmarks/start.php') diff --git a/mod/bookmarks/start.php b/mod/bookmarks/start.php index 21a2d8940..56bac984a 100644 --- a/mod/bookmarks/start.php +++ b/mod/bookmarks/start.php @@ -245,21 +245,15 @@ function bookmarks_notify_message($hook, $entity_type, $returnvalue, $params) { if (($entity instanceof ElggEntity) && ($entity->getSubtype() == 'bookmarks')) { $descr = $entity->description; $title = $entity->title; - global $CONFIG; - $url = elgg_get_site_url() . "view/" . $entity->guid; - if ($method == 'sms') { - $owner = $entity->getOwnerEntity(); - return $owner->name . ' ' . elgg_echo("bookmarks:via") . ': ' . $url . ' (' . $title . ')'; - } - if ($method == 'email') { - $owner = $entity->getOwnerEntity(); - return $owner->name . ' ' . elgg_echo("bookmarks:via") . ': ' . $title . "\n\n" . $descr . "\n\n" . $entity->getURL(); - } - if ($method == 'web') { - $owner = $entity->getOwnerEntity(); - return $owner->name . ' ' . elgg_echo("bookmarks:via") . ': ' . $title . "\n\n" . $descr . "\n\n" . $entity->getURL(); - } - + $owner = $entity->getOwnerEntity(); + + return elgg_echo('bookmarks:notification', array( + $owner->name, + $title, + $entity->address, + $descr, + $entity->getURL() + )); } return null; } -- cgit v1.2.3