We don't really need the unsen bit in api_lists_statuses()
This commit is contained in:
parent
b3235c2d02
commit
929440417c
1 changed files with 0 additions and 16 deletions
|
@ -3408,22 +3408,6 @@ function api_lists_statuses($type)
|
||||||
|
|
||||||
$ret = api_format_items($r, $user_info, false, $type);
|
$ret = api_format_items($r, $user_info, false, $type);
|
||||||
|
|
||||||
// Set all posts from the query above to seen
|
|
||||||
$idarray = [];
|
|
||||||
foreach ($r as $item) {
|
|
||||||
$idarray[] = intval($item["id"]);
|
|
||||||
}
|
|
||||||
|
|
||||||
$idlist = implode(",", $idarray);
|
|
||||||
|
|
||||||
if ($idlist != "") {
|
|
||||||
$unseen = q("SELECT `id` FROM `item` WHERE `unseen` AND `id` IN (%s)", $idlist);
|
|
||||||
|
|
||||||
if ($unseen) {
|
|
||||||
q("UPDATE `item` SET `unseen` = 0 WHERE `unseen` AND `id` IN (%s)", $idlist);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
$data = ['status' => $ret];
|
$data = ['status' => $ret];
|
||||||
switch ($type) {
|
switch ($type) {
|
||||||
case "atom":
|
case "atom":
|
||||||
|
|
Loading…
Reference in a new issue