diff --git a/CHANGELOG.md b/CHANGELOG.md index 3e10fbb..1227110 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,7 @@ ### Fixes - Fixed `Paginator` throwing an exception when reaching the end of pagination, instead of just ending its iteration +- Fixed `Paginator` defaulting to start at 0 for all iterations ## v0.0.11 diff --git a/disco/util/paginator.py b/disco/util/paginator.py index 4f705e9..f6c538f 100644 --- a/disco/util/paginator.py +++ b/disco/util/paginator.py @@ -13,7 +13,7 @@ class Paginator(object): self._key = kwargs.pop('key', operator.attrgetter('id')) self._bulk = kwargs.pop('bulk', False) - self._sort_key_value = kwargs.pop(self.sort_key, 0) + self._sort_key_value = kwargs.pop(self.sort_key, None) self._buffer = [] def fill(self):