chore (mark_as_read.py): reduce a nested for loop to enhance readability
This commit is contained in:
parent
3a96009467
commit
4d2d863fb7
@ -47,12 +47,14 @@ def get_ids_older_ndays():
|
|||||||
|
|
||||||
entries = request_unread.json()
|
entries = request_unread.json()
|
||||||
|
|
||||||
if entries["entries"]:
|
if not entries["entries"]:
|
||||||
for item in entries["entries"]:
|
return
|
||||||
if item['feed']['category']['title'] in config['options']['ignore']:
|
|
||||||
continue
|
|
||||||
|
|
||||||
id_array.append(item["id"])
|
for item in entries["entries"]:
|
||||||
|
if item['feed']['category']['title'] in config['options']['ignore']:
|
||||||
|
continue
|
||||||
|
|
||||||
|
id_array.append(item["id"])
|
||||||
|
|
||||||
def mark_as_read():
|
def mark_as_read():
|
||||||
""" mark ids from id_array as read
|
""" mark ids from id_array as read
|
||||||
|
Reference in New Issue
Block a user