X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=actions%2Fallrss.php;h=885a67f6188af13b07a0ea7e6bf9a8302078e476;hb=bd9824c8d563bbd2d9f9ed259341f0e2fc1ffdf1;hp=05787f3f73cb8cdc5398cb4dc8c7140facc371cc;hpb=d06a929d703e0ad776230234b3d821a83f22d492;p=quix0rs-gnu-social.git diff --git a/actions/allrss.php b/actions/allrss.php index 05787f3f73..885a67f618 100644 --- a/actions/allrss.php +++ b/actions/allrss.php @@ -13,7 +13,7 @@ * @link http://laconi.ca/ * * Laconica - a distributed open-source microblogging tool - * Copyright (C) 2008, Controlez-Vous, Inc. + * Copyright (C) 2008, 2009, Control Yourself, Inc. * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Affero General Public License as published by @@ -53,7 +53,9 @@ class AllrssAction extends Rss10Action /** * Initialization. - * + * + * @param array $args Web and URL arguments + * * @return boolean false if user doesn't exist */ function prepare($args) @@ -79,9 +81,18 @@ class AllrssAction extends Rss10Action */ function getNotices($limit=0) { - $user = $this->user; - $notice = $user->noticesWithFriends(0, $limit); - + $cur = common_current_user(); + + if (!empty($cur) && $cur->id == $user->id) { + $notice = $this->user->noticeInbox(0, $limit); + } else { + $notice = $this->user->noticesWithFriends(0, $limit); + } + + $user = $this->user; + $notice = $user->noticesWithFriends(0, $limit); + $notices = array(); + while ($notice->fetch()) { $notices[] = clone($notice); } @@ -104,7 +115,8 @@ class AllrssAction extends Rss10Action 'link' => common_local_url('all', array('nickname' => $user->nickname)), - 'description' => sprintf(_('Feed for friends of %s'), $user->nickname)); + 'description' => sprintf(_('Feed for friends of %s'), + $user->nickname)); return $c; } @@ -123,10 +135,5 @@ class AllrssAction extends Rss10Action $avatar = $profile->getAvatar(AVATAR_PROFILE_SIZE); return $avatar ? $avatar->url : null; } - - function isReadOnly() - { - return true; - } }