This commit is contained in:
Friendika 2011-09-26 23:39:47 -07:00
parent ec16525c86
commit e04d9b8646
2 changed files with 13 additions and 5 deletions

View file

@ -7,7 +7,7 @@ require_once('include/text.php');
require_once("include/pgettext.php"); require_once("include/pgettext.php");
define ( 'FRIENDIKA_VERSION', '2.3.1115' ); define ( 'FRIENDIKA_VERSION', '2.3.1116' );
define ( 'DFRN_PROTOCOL_VERSION', '2.21' ); define ( 'DFRN_PROTOCOL_VERSION', '2.21' );
define ( 'DB_UPDATE_VERSION', 1092 ); define ( 'DB_UPDATE_VERSION', 1092 );

View file

@ -107,10 +107,18 @@ function delivery_run($argv, $argc){
return; return;
} }
$icontacts = q("SELECT * FROM `contact` WHERE `id` IN ( SELECT distinct(`contact-id`) FROM `item` where `parent` = %d ) ", $icontacts = null;
intval($parent_id) $contacts_arr = array();
); foreach($items as $item)
if(! count($icontacts)) if(! in_array($item['contact-id'],$contacts_arr))
$contacts_arr[] = intval($item['contact-id']);
if(count($contacts_arr)) {
$str_contacts = implode(',',$contacts_arr);
$icontacts = q("SELECT * FROM `contact`
WHERE `id` IN ( $str_contacts ) "
);
}
if( ! ($icontacts && count($icontacts)))
return; return;