mirror of
https://github.com/github/octodns.git
synced 2024-05-11 05:55:00 +00:00
Add more explicit constant name for pagination
Co-Authored-By: Ross McFarland <ross@github.com>
This commit is contained in:
committed by
Anton Shnayder
parent
57c96cf40f
commit
76a9d358e8
@@ -28,7 +28,7 @@ class SelectelProvider(BaseProvider):
|
||||
|
||||
MIN_TTL = 60
|
||||
|
||||
LIMIT = 50
|
||||
PAGINATION_LIMIT = 50
|
||||
|
||||
API_URL = 'https://api.selectel.ru/domains/v1'
|
||||
|
||||
@@ -69,9 +69,9 @@ class SelectelProvider(BaseProvider):
|
||||
|
||||
def _request_with_pagination(self, path, total_count):
|
||||
result = []
|
||||
for offset in range(0, total_count, self.LIMIT):
|
||||
for offset in range(0, total_count, self.PAGINATION_LIMIT):
|
||||
result += self._request('GET', path,
|
||||
params={'limit': self.LIMIT,
|
||||
params={'limit': self.PAGINATION_LIMIT,
|
||||
'offset': offset})
|
||||
return result
|
||||
|
||||
|
Reference in New Issue
Block a user