* @link http://status.net/
*/
-if (!defined('STATUSNET')) {
- // This check helps protect against security problems;
- // your code file can't be executed directly from the web.
- exit(1);
-}
+if (!defined('GNUSOCIAL')) { exit(1); }
/**
* Public stream
* @link http://status.net/
*/
-class PublicNoticeStream extends ScopingNoticeStream
+class PublicNoticeStream extends ModeratedNoticeStream
{
- function __construct($profile=null)
+ function __construct(Profile $scoped=null)
{
parent::__construct(new CachingNoticeStream(new RawPublicNoticeStream(),
'public'),
- $profile);
+ $scoped);
}
}
* @link http://status.net/
*/
-class RawPublicNoticeStream extends NoticeStream
+class RawPublicNoticeStream extends FullNoticeStream
{
function getNoticeIds($offset, $limit, $since_id, $max_id)
{
Notice::addWhereSinceId($notice, $since_id);
Notice::addWhereMaxId($notice, $max_id);
- if (!empty($this->selectVerbs)) {
- $notice->whereAddIn('verb', $this->selectVerbs, $notice->columnType('verb'));
- }
+ self::filterVerbs($notice, $this->selectVerbs);
$ids = array();