Speeding up showing marked posts.
This commit is contained in:
parent
35048819ff
commit
046096e705
1 changed files with 5 additions and 1 deletions
|
@ -575,6 +575,10 @@ function network_content(&$a, $update = 0) {
|
||||||
//$sql_nets = (($nets) ? sprintf(" and `contact`.`network` = '%s' ", dbesc($nets)) : '');
|
//$sql_nets = (($nets) ? sprintf(" and `contact`.`network` = '%s' ", dbesc($nets)) : '');
|
||||||
$sql_nets = (($nets) ? sprintf(" and `item`.`network` = '%s' ", dbesc($nets)) : '');
|
$sql_nets = (($nets) ? sprintf(" and `item`.`network` = '%s' ", dbesc($nets)) : '');
|
||||||
|
|
||||||
|
if ($star OR $bmark) {
|
||||||
|
$sql_table = "`item` INNER JOIN (SELECT DISTINCT(`parent`) FROM `item` WHERE 1 $sql_options and deleted = 0 ORDER BY `commented` DESC) AS `temp1` ON item.parent = `temp1`.parent ";
|
||||||
|
$sql_extra = "";
|
||||||
|
} else
|
||||||
$sql_extra = " AND `item`.`parent` IN ( SELECT `parent` FROM `item` WHERE `id` = `parent` $sql_options ) ";
|
$sql_extra = " AND `item`.`parent` IN ( SELECT `parent` FROM `item` WHERE `id` = `parent` $sql_options ) ";
|
||||||
|
|
||||||
if($group) {
|
if($group) {
|
||||||
|
|
Loading…
Reference in a new issue