aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorMario Vavti <mario@mariovavti.com>2019-04-27 15:35:41 +0200
committerMario Vavti <mario@mariovavti.com>2019-04-27 15:35:41 +0200
commit73248aadd5a3d862002d3afcd2cecd4ea8436fa3 (patch)
treee25a60091e10293c10a7d4d5a377f3db9a7356d6 /include
parenta518471a270795425a2b835fae585d26303beebd (diff)
downloadvolse-hubzilla-73248aadd5a3d862002d3afcd2cecd4ea8436fa3.tar.gz
volse-hubzilla-73248aadd5a3d862002d3afcd2cecd4ea8436fa3.tar.bz2
volse-hubzilla-73248aadd5a3d862002d3afcd2cecd4ea8436fa3.zip
possible sql performance improvement
Diffstat (limited to 'include')
-rwxr-xr-xinclude/items.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/items.php b/include/items.php
index c08deb3a0..95b696034 100755
--- a/include/items.php
+++ b/include/items.php
@@ -4278,7 +4278,7 @@ function items_fetch($arr,$channel = null,$observer_hash = null,$client_mode = C
if($arr['mid'])
$sql_options .= " and parent_mid = '" . dbesc($arr['mid']) . "' ";
- $sql_extra = " AND item.parent IN ( SELECT parent FROM item WHERE item_thread_top = 1 $sql_options $item_normal ) ";
+ $sql_extra = " AND item.parent IN ( SELECT parent FROM item WHERE $item_uids and item_thread_top = 1 $sql_options $item_normal ) ";
if($arr['since_id'])
$sql_extra .= " and item.id > " . $since_id . " ";