diff options
| author | Gary Wilson Jr <gary.wilson@gmail.com> | 2008-07-27 23:01:55 +0000 |
|---|---|---|
| committer | Gary Wilson Jr <gary.wilson@gmail.com> | 2008-07-27 23:01:55 +0000 |
| commit | 9a5301ccbc08d5e4f78ae6a8a39330196cdd5f66 (patch) | |
| tree | c0fc017ea0f280e82ce49a24a6eb6a5a47d8ba8c /docs/modpython.txt | |
| parent | 6a287ed946e117d9daf757b9aff52087c93ad2ac (diff) | |
Made the Paginator class a bit more backwards compatible with the lecacy `ObjectPaginator` class by using the `ObjectPaginator`'s `_get_count` method. Instead of explicitly checking for an instance of `QuerySet`, this now allows any object with a `count()` or `__len__()` method defined to be passed to Paginator. For one, this is useful when you have custom `QuerySet`-like classes that implement a `count()` method but don't inherit from `QuerySet` explicitly.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@8121 bcc190cf-cafb-0310-a4f2-bffc1f526a37
Diffstat (limited to 'docs/modpython.txt')
0 files changed, 0 insertions, 0 deletions
