public function getQueryInfo()
 {
     global $wgExcludedWantedFiles;
     $queryInfo = parent::getQueryInfo();
     if (!empty($wgExcludedWantedFiles) && is_array($wgExcludedWantedFiles)) {
         $dbr = wfGetDB(DB_SLAVE);
         $queryInfo['conds'][] = "il_to not in (" . $dbr->makeList($wgExcludedWantedFiles) . ") ";
     }
     return $queryInfo;
 }
 /**
  * Returns additional query conditions to use when constructing the wanted files SQL.  In this case we
  * are adding:
  * - the ability to filter out specific files by file name.
  * - a filter to remove premium video results which do not have image table entries
  *
  * @return array
  */
 public function getQueryInfo()
 {
     global $wgExcludedWantedFiles;
     $queryInfo = parent::getQueryInfo();
     if (!empty($wgExcludedWantedFiles) && is_array($wgExcludedWantedFiles)) {
         $dbr = wfGetDB(DB_SLAVE);
         $queryInfo['conds'][] = "il_to not in (" . $dbr->makeList($wgExcludedWantedFiles) . ") ";
     }
     // Ignore any missing images that are actually premium video.  Premium video comes from the
     // video.wikia.com wiki and will not have local image table entries
     $queryInfo['tables'][] = 'video_info';
     $queryInfo['join_conds']['video_info'] = array('LEFT JOIN', array("il_to = video_title", "premium = 1"));
     $queryInfo['conds'][] = 'video_title IS NULL';
     return $queryInfo;
 }