X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=classes%2FNotice_tag.php;h=a5d0716a7136d6b00c073b0679f7afe273340eb0;hb=c6f09306b1c72296db8b55500a5d6a2ea8cd5dd2;hp=79231f0b0c0777749c09cf91da451192ed55cb2f;hpb=e53512cd2c2180f81fc7317de9df09a140099aa3;p=quix0rs-gnu-social.git diff --git a/classes/Notice_tag.php b/classes/Notice_tag.php index 79231f0b0c..a5d0716a71 100644 --- a/classes/Notice_tag.php +++ b/classes/Notice_tag.php @@ -46,7 +46,7 @@ class Notice_tag extends Memcached_DataObject return Notice::getStreamByIds($ids); } - function _streamDirect($tag, $offset, $limit, $since_id, $max_id, $since) + function _streamDirect($tag, $offset, $limit, $since_id, $max_id) { $nt = new Notice_tag(); @@ -63,10 +63,6 @@ class Notice_tag extends Memcached_DataObject $nt->whereAdd('notice_id < ' . $max_id); } - if (!is_null($since)) { - $nt->whereAdd('created > \'' . date('Y-m-d H:i:s', $since) . '\''); - } - $nt->orderBy('notice_id DESC'); if (!is_null($offset)) { @@ -86,13 +82,9 @@ class Notice_tag extends Memcached_DataObject function blowCache($blowLast=false) { - $cache = common_memcache(); - if ($cache) { - $idkey = common_cache_key('notice_tag:notice_ids:' . common_keyize($this->tag)); - $cache->delete($idkey); - if ($blowLast) { - $cache->delete($idkey.';last'); - } + self::blow('notice_tag:notice_ids:%s', common_keyize($this->tag)); + if ($blowLast) { + self::blow('notice_tag:notice_ids:%s;last', common_keyize($this->tag)); } }