Skip to content

Commit

Permalink
Update method usage to match changes in 3.0
Browse files Browse the repository at this point in the history
Query::total() was renamed to Query::count().
  • Loading branch information
markstory committed Nov 21, 2013
1 parent 8874ec3 commit e5bd7a9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Cake/Controller/Component/PaginatorComponent.php
Expand Up @@ -188,7 +188,7 @@ public function paginate($object, $settings = array(), $whitelist = array()) {
$count = 0;
} else {
$parameters = compact('conditions');
$count = $object->find($type, array_merge($parameters, $extra))->total();
$count = $object->find($type, array_merge($parameters, $extra))->count();
}

$pageCount = intval(ceil($count / $limit));
Expand Down

0 comments on commit e5bd7a9

Please sign in to comment.