+
+ private function getLogQueryCond() {
+ $ids = $safeIds = array();
+ switch( $this->deleteKey ) {
+ case 'oldid':
+ $ids = $this->oldids;
+ break;
+ case 'artimestamp':
+ $ids = $this->artimestamps;
+ break;
+ case 'oldimage':
+ $ids = $this->oldimgs;
+ break;
+ case 'fileid':
+ $ids = $this->fileids;
+ break;
+ case 'logid':
+ $ids = $this->logids;
+ break;
+ }
+ // Digit chars only
+ foreach( $ids as $id ) {
+ if( preg_match( '/^\d+$/', $id, $m ) ) {
+ $safeIds[] = $m[0];
+ }
+ }
+ if( count($safeIds) ) {
+ return array("log_params RLIKE '".implode('|',$safeIds)."'");
+ }
+ return null;
+ }