[instagram] allow disabling 'cursor' output

This commit is contained in:
Mike Fährmann
2024-08-17 19:04:17 +02:00
parent c0668f5106
commit e29f4ef226
2 changed files with 23 additions and 1 deletions

View File

@@ -378,7 +378,11 @@ class InstagramExtractor(Extractor):
"full_name": user["full_name"]})
def _init_cursor(self):
return self.config("cursor") or None
cursor = self.config("cursor", True)
if not cursor:
self._update_cursor = util.identity
elif isinstance(cursor, str):
return cursor
def _update_cursor(self, cursor):
self.log.debug("Cursor: %s", cursor)