summaryrefslogtreecommitdiff
path: root/classes
diff options
context:
space:
mode:
authorZach Copley <zach@status.net>2010-05-05 14:46:36 -0700
committerZach Copley <zach@status.net>2010-05-05 14:46:36 -0700
commitb50f300566143837aba3739d62caf679ec19727e (patch)
tree152f809555ade259ac5488243e2433c223f6ae7e /classes
parentc2bda7726c05c6c7f5ef4f9519e56f107bc4e1e5 (diff)
Implement since_id and max_id param handling for /api/favorites
Diffstat (limited to 'classes')
-rw-r--r--classes/Fave.php4
-rw-r--r--classes/User.php4
2 files changed, 4 insertions, 4 deletions
diff --git a/classes/Fave.php b/classes/Fave.php
index 7ca9ade7f..ed4f56aee 100644
--- a/classes/Fave.php
+++ b/classes/Fave.php
@@ -75,13 +75,13 @@ class Fave extends Memcached_DataObject
return Memcached_DataObject::pkeyGet('Fave', $kv);
}
- function stream($user_id, $offset=0, $limit=NOTICES_PER_PAGE, $own=false)
+ function stream($user_id, $offset=0, $limit=NOTICES_PER_PAGE, $own=false, $since_id=0, $max_id=0)
{
$ids = Notice::stream(array('Fave', '_streamDirect'),
array($user_id, $own),
($own) ? 'fave:ids_by_user_own:'.$user_id :
'fave:ids_by_user:'.$user_id,
- $offset, $limit);
+ $offset, $limit, $since_id, $max_id);
return $ids;
}
diff --git a/classes/User.php b/classes/User.php
index 1928a3c62..2abb7eeb6 100644
--- a/classes/User.php
+++ b/classes/User.php
@@ -464,9 +464,9 @@ class User extends Memcached_DataObject
return $profile->getNotices($offset, $limit, $since_id, $before_id);
}
- function favoriteNotices($offset=0, $limit=NOTICES_PER_PAGE, $own=false)
+ function favoriteNotices($own=false, $offset=0, $limit=NOTICES_PER_PAGE, $since_id=0, $max_id=0)
{
- $ids = Fave::stream($this->id, $offset, $limit, $own);
+ $ids = Fave::stream($this->id, $offset, $limit, $own, $since_id, $max_id);
return Notice::getStreamByIds($ids);
}