cakephp/cakephp — pull request #3018 by lorenzo (2014-03-13 22:27:20+00:00)
Title: 3.0 paginator revisit

This add the ability to pass an already created query instance to `paginate()`

```php
function index() {
$query = $this->Articles->find('popular')->matching('Tags', function($q) {
return $q->where(['name' => 'CakePHP'])
});
$this->set($articles, $this->paginate($query));
}
```