From: Roland Häder Date: Fri, 28 Jun 2013 22:07:44 +0000 (+0000) Subject: Fixed more generic array handling #2 X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=7f99b7b2ea144617b530e117b56585f47cb9509e;p=core.git Fixed more generic array handling #2 --- diff --git a/inc/classes/main/criteria/class_BaseCriteria.php b/inc/classes/main/criteria/class_BaseCriteria.php index 7ba2ea57..78a4e828 100644 --- a/inc/classes/main/criteria/class_BaseCriteria.php +++ b/inc/classes/main/criteria/class_BaseCriteria.php @@ -293,7 +293,7 @@ class BaseCriteria extends BaseFrameworkSystem implements Criteria { $key = $this->convertDashesToUnderscores($key); // Then walk through all search criteria - foreach ($this->getGenericSubArray('criteria', $criteriaType) as $criteriaKey => $criteriaValue) { + foreach ($this->getGenericArrayKey('criteria', $criteriaType, 'entries') as $criteriaKey => $criteriaValue) { // Make sure no 'my-' or 'my_' passes this point assert((strpos($criteriaKey, 'my-') === FALSE) && (strpos($criteriaKey, 'my_') === FALSE) && (!is_bool($criteriaValue))); @@ -355,9 +355,10 @@ class BaseCriteria extends BaseFrameworkSystem implements Criteria { $cacheKey = ''; // Now walk through all criterias - foreach ($this->getGenericSubArray('criteria', $criteriaType) as $criteriaKey => $criteriaValue) { + foreach ($this->getGenericArrayKey('criteria', $criteriaType, 'entries') as $criteriaKey => $criteriaValue) { // Make sure no 'my-' or 'my_' passes this point assert((strpos($criteriaKey, 'my-') === FALSE) && (strpos($criteriaKey, 'my_') === FALSE) && (!is_bool($criteriaValue))); + assert(!is_array($criteriaValue)); // Convert dashes to underscore $criteriaKey = $this->convertDashesToUnderscores($criteriaKey);