diff --git a/includes/basetype.class.php b/includes/basetype.class.php index 5e9e9f0c..b016bea8 100644 --- a/includes/basetype.class.php +++ b/includes/basetype.class.php @@ -262,19 +262,7 @@ abstract class BaseType foreach ($this->dbNames as $dbIdx => $n) { $query = str_replace('DB_IDX', $dbIdx, $this->queryBase); - - if (key($this->dbNames) === 0) - { - if ($rows = DB::{$n}($dbIdx)->select($query)) - { - $mtchQry = preg_replace('/SELECT .*? FROM/', 'SELECT count(1) FROM', $this->queryBase); - $mtch = DB::{$n}($dbIdx)->selectCell($mtchQry); - } - } - else - $rows = DB::{$n}($dbIdx)->SelectPage($mtch, $query); - - if ($rows) + if ($rows = DB::{$n}($dbIdx)->SelectPage($mtch, $query)) { $this->matches += $mtch; foreach ($rows as $id => $row)