From f210cadfecc4f87e1fb8e35cd784a7010c443c31 Mon Sep 17 00:00:00 2001 From: Zach Copley Date: Wed, 3 Mar 2010 17:35:18 -0800 Subject: Revert "Revert "Show and no activity actors for user feed"" This reverts commit e2578cfad68c45ca177c51997c4cc7c0abafbd9a. --- lib/atomnoticefeed.php | 16 +++++++++++++--- lib/atomusernoticefeed.php | 11 +++++++++++ 2 files changed, 24 insertions(+), 3 deletions(-) (limited to 'lib') diff --git a/lib/atomnoticefeed.php b/lib/atomnoticefeed.php index 3c3556cb9..e4df731fe 100644 --- a/lib/atomnoticefeed.php +++ b/lib/atomnoticefeed.php @@ -107,9 +107,19 @@ class AtomNoticeFeed extends Atom10Feed */ function addEntryFromNotice($notice) { - $this->addEntryRaw($notice->asAtomEntry()); - } + $source = $this->showSource(); + $author = $this->showAuthor(); -} + $this->addEntryRaw($notice->asAtomEntry(false, $source, $author)); + } + function showSource() + { + return true; + } + function showAuthor() + { + return true; + } +} diff --git a/lib/atomusernoticefeed.php b/lib/atomusernoticefeed.php index 55cebef6d..428cc2de2 100644 --- a/lib/atomusernoticefeed.php +++ b/lib/atomusernoticefeed.php @@ -61,6 +61,7 @@ class AtomUserNoticeFeed extends AtomNoticeFeed if (!empty($user)) { $profile = $user->getProfile(); $this->addAuthor($profile->nickname, $user->uri); + $this->setActivitySubject($profile->asActivityNoun('subject')); } $title = sprintf(_("%s timeline"), $user->nickname); @@ -105,4 +106,14 @@ class AtomUserNoticeFeed extends AtomNoticeFeed { return $this->user; } + + function showSource() + { + return false; + } + + function showAuthor() + { + return false; + } } -- cgit v1.2.3-54-g00ecf