Skip to content

Commit 1be9b4a

Browse files
committed
instanceof
1 parent e895e90 commit 1be9b4a

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

class/TagHandler.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -273,7 +273,7 @@ public function &getByLimit(
273273
$start = null;
274274
$sort = '';
275275
$order = '';
276-
if (null !== $criteria && is_subclass_of($criteria, 'CriteriaCompo')) {
276+
if (null !== $criteria && $criteria instanceof \CriteriaCompo) {
277277
$sql .= ' ' . $criteria->renderWhere();
278278
$sort = $criteria->getSort();
279279
$order = $criteria->getOrder();
@@ -336,7 +336,7 @@ public function getCount(\CriteriaElement $criteria = null)
336336
$modid = (int)($modid);
337337
*/
338338
$sql = "SELECT COUNT(DISTINCT o.{$this->keyName})" . " FROM {$this->table} AS o LEFT JOIN {$this->table_link} AS l ON l.{$this->keyName} = o.{$this->keyName}";
339-
if ((null !== $criteria) && is_subclass_of($criteria, 'CriteriaElement')) {
339+
if ((null !== $criteria) && $criteria instanceof \CriteriaElement) {
340340
$sql .= ' ' . $criteria->renderWhere();
341341
}
342342
/*
@@ -377,7 +377,7 @@ public function getItems(\CriteriaElement $criteria = null)
377377
$start = null;
378378
$sort = '';
379379
$order = '';
380-
if ((null !== $criteria) && is_subclass_of($criteria, 'CriteriaElement')) {
380+
if ((null !== $criteria) && $criteria instanceof \CriteriaElement) {
381381
$sql .= ' ' . $criteria->renderWhere();
382382
$sort = $criteria->getSort();
383383
$order = $criteria->getOrder();

0 commit comments

Comments
 (0)