mirror of
https://github.com/nadimkobeissi/mkbsd.git
synced 2025-01-08 19:15:36 +00:00
Update mkbsd.py
Add count of images before starting download
This commit is contained in:
parent
82e50c64f0
commit
8837253d9f
3
mkbsd.py
3
mkbsd.py
|
@ -30,6 +30,9 @@ async def main():
|
||||||
json_data = await response.json()
|
json_data = await response.json()
|
||||||
data = json_data.get('data')
|
data = json_data.get('data')
|
||||||
|
|
||||||
|
count = len(data) if data else 0
|
||||||
|
print(f"Found {count} images..")
|
||||||
|
|
||||||
if not data:
|
if not data:
|
||||||
raise Exception('⛔ JSON does not have a "data" property at its root.')
|
raise Exception('⛔ JSON does not have a "data" property at its root.')
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue