Set self.count before self.limit in LimitOffsetPagination
Set self.count before self.limit in LimitOffsetPagination

By doing this it is possible to override get_limit in order to return all records if the request has a predefined param.

For example, if one wants that all records are retrieved if url has &limit=-1, get_limit could return self.count in this case.

Otherwise, if self.count is set after self.limit then, to achive the same result, one has to override get_limit and paginate_queryset, or run get_limit twice.
jpadilla/django-rest-framework,davesque/django-rest-framework,ossanna16/django-rest-framework,edx/django-rest-framework,dmwyatt/django-rest-framework,dmwyatt/django-rest-framework,davesque/django-rest-framework,dmwyatt/django-rest-framework,edx/django-rest-framework,edx/django-rest-framework,atombrella/django-rest-framework,tomchristie/django-rest-framework,atombrella/django-rest-framework,ossanna16/django-rest-framework,kgeorgy/django-rest-framework,jpadilla/django-rest-framework,linovia/django-rest-framework,atombrella/django-rest-framework,ossanna16/django-rest-framework,linovia/django-rest-framework,linovia/django-rest-framework,kgeorgy/django-rest-framework,jpadilla/django-rest-framework,tomchristie/django-rest-framework,tomchristie/django-rest-framework,davesque/django-rest-framework,kgeorgy/django-rest-framework