fix-#759: with_limit_and_skip for count should default like in pymongo

This commit is contained in:
DavidBord
2014-11-07 09:18:42 +02:00
parent 201b12a886
commit 914c5752a5
5 changed files with 13 additions and 7 deletions

View File

@@ -384,7 +384,7 @@ class BaseQuerySet(object):
self._document, documents=results, loaded=True)
return return_one and results[0] or results
def count(self, with_limit_and_skip=True):
def count(self, with_limit_and_skip=False):
"""Count the selected elements in the query.
:param with_limit_and_skip (optional): take any :meth:`limit` or

View File

@@ -94,7 +94,7 @@ class QuerySet(BaseQuerySet):
except StopIteration:
self._has_more = False
def count(self, with_limit_and_skip=True):
def count(self, with_limit_and_skip=False):
"""Count the selected elements in the query.
:param with_limit_and_skip (optional): take any :meth:`limit` or