X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=include%2Fonepoll.php;h=951b87043e06d8a014f81ad365eb62d8b5abfdc3;hb=5e188a9250d42a82cd6b8e84d65875f3bc6067fb;hp=eb1045de142957dcab4e08d8b66ff8aa3ecb4750;hpb=01b02dbcaa8532f965389375e961d9c47d74eeec;p=friendica.git diff --git a/include/onepoll.php b/include/onepoll.php index eb1045de14..951b87043e 100644 --- a/include/onepoll.php +++ b/include/onepoll.php @@ -24,7 +24,6 @@ function onepoll_run(&$argv, &$argc){ unset($db_host, $db_user, $db_pass, $db_data); }; - require_once('include/session.php'); require_once('include/datetime.php'); require_once('include/items.php'); @@ -444,7 +443,7 @@ function onepoll_run(&$argv, &$argc){ $refs_arr[$x] = "'" . msgid2iri(str_replace(array('<','>',' '),array('','',''),dbesc($refs_arr[$x]))) . "'"; } $qstr = implode(',',$refs_arr); - $r = q("SELECT `uri` , `parent-uri` FROM `item` WHERE `uri` IN ( $qstr ) AND `uid` = %d LIMIT 1", + $r = q("SELECT `uri` , `parent-uri` FROM `item` USE INDEX (`uid_uri`) WHERE `uri` IN ($qstr) AND `uid` = %d LIMIT 1", intval($importer_uid) ); if(count($r))