error cleanup
This commit is contained in:
parent
91e4c2fce1
commit
359c74d320
@ -3760,10 +3760,12 @@ function fetch_post_tags($items) {
|
||||
$tag_finder[] = $item['item_id'];
|
||||
$tag_finder_str = implode(', ', $tag_finder);
|
||||
|
||||
$tags = q("select * from term where oid in ( %s ) and otype = %d",
|
||||
dbesc($tag_finder_str),
|
||||
intval(TERM_OBJ_POST)
|
||||
);
|
||||
if(strlen($tag_finder_str)) {
|
||||
$tags = q("select * from term where oid in ( %s ) and otype = %d",
|
||||
dbesc($tag_finder_str),
|
||||
intval(TERM_OBJ_POST)
|
||||
);
|
||||
}
|
||||
|
||||
for($x = 0; $x < count($items); $x ++) {
|
||||
if(count($tags)) {
|
||||
|
@ -278,18 +278,6 @@ function content_content(&$a, $update = 0) {
|
||||
|
||||
$second = dba_timer();
|
||||
|
||||
$tag_finder = array();
|
||||
if(count($items))
|
||||
foreach($items as $item)
|
||||
if(! in_array($item['item_id'],$tag_finder))
|
||||
$tag_finder[] = $item['item_id'];
|
||||
$tag_finder_str = implode(', ', $tag_finder);
|
||||
|
||||
$tags = q("select * from term where oid in ( %s ) and otype = %d",
|
||||
dbesc($tag_finder_str),
|
||||
intval(TERM_OBJ_POST)
|
||||
);
|
||||
|
||||
$items = fetch_post_tags($items);
|
||||
$items = conv_sort($items,$ordering);
|
||||
|
||||
|
@ -614,6 +614,8 @@ function network_content(&$a, $update = 0) {
|
||||
intval($_SESSION['uid'])
|
||||
);
|
||||
|
||||
require_once('include/items.php');
|
||||
|
||||
$items = fetch_post_tags($items);
|
||||
}
|
||||
else {
|
||||
|
@ -282,17 +282,6 @@ function profile_content(&$a, $update = 0) {
|
||||
dbesc($parents_str)
|
||||
);
|
||||
|
||||
$tag_finder = array();
|
||||
if(count($items))
|
||||
foreach($items as $item)
|
||||
if(! in_array($item['item_id'],$tag_finder))
|
||||
$tag_finder[] = $item['item_id'];
|
||||
$tag_finder_str = implode(', ', $tag_finder);
|
||||
$tags = q("select * from term where oid in ( '%s' ) and otype = %d",
|
||||
dbesc($tag_finder_str),
|
||||
intval(TERM_OBJ_POST)
|
||||
);
|
||||
|
||||
$items = fetch_post_tags($items);
|
||||
$items = conv_sort($items,'created');
|
||||
|
||||
|
Reference in New Issue
Block a user