From 2518e4730b7322fe3ca57155ee53911dc6909e97 Mon Sep 17 00:00:00 2001 From: Sarjuuk Date: Sat, 7 Apr 2018 20:36:09 +0200 Subject: [PATCH] BaseType * revert change to get number total results this partially reverts bf42973c --- includes/basetype.class.php | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) 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)