2
0
Просмотр исходного кода

ZF-6989: fixed issue with cache and wrong calculated internal cacheId

git-svn-id: http://framework.zend.com/svn/framework/standard/trunk@22302 44c647ce-9c0f-0410-b52a-842ac1e357ba
bate 15 лет назад
Родитель
Сommit
102eaa299e
1 измененных файлов с 5 добавлено и 2 удалено
  1. 5 2
      library/Zend/Paginator.php

+ 5 - 2
library/Zend/Paginator.php

@@ -93,7 +93,7 @@ class Zend_Paginator implements Countable, IteratorAggregate
     protected static $_cache;
 
     /**
-     * Enable or desable the cache by Zend_Paginator instance
+     * Enable or disable the cache by Zend_Paginator instance
      *
      * @var bool
      */
@@ -1012,7 +1012,10 @@ class Zend_Paginator implements Countable, IteratorAggregate
      */
     protected function _getCacheInternalId()
     {
-        return md5(serialize($this->getAdapter()) . $this->getItemCountPerPage());
+        return md5(serialize(array(
+            get_class($this->getAdapter()),
+            $this->getItemCountPerPage()
+        )));
     }
 
     /**