aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCédric Bonhomme <cedric@cedricbonhomme.org>2021-07-02 17:48:17 +0200
committerCédric Bonhomme <cedric@cedricbonhomme.org>2021-07-02 17:48:17 +0200
commit9c0c7b691d70c161acaee6e641d6fcced298d63f (patch)
tree381dee5f889236ab6861116d07ee98e903e8d030
parentupdated copyright years (diff)
downloadnewspipe-9c0c7b691d70c161acaee6e641d6fcced298d63f.tar.gz
newspipe-9c0c7b691d70c161acaee6e641d6fcced298d63f.tar.bz2
newspipe-9c0c7b691d70c161acaee6e641d6fcced298d63f.zip
delete read articles retrieved since more than 15 days.
-rwxr-xr-xnewspipe/commands.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/newspipe/commands.py b/newspipe/commands.py
index 06b7dda9..12ddb486 100755
--- a/newspipe/commands.py
+++ b/newspipe/commands.py
@@ -101,11 +101,11 @@ def disable_inactive_users(last_seen):
@application.cli.command("delete_read_articles")
def delete_read_articles():
- "Delete read articles retrieved since more than 5 days ago."
+ "Delete read articles retrieved since more than 15 days ago."
filter = {}
filter["user_id__ne"] = 1
#filter["readed"] = True # temporary comment
- filter["retrieved_date__lt"] = date.today() - relativedelta(days=5)
+ filter["retrieved_date__lt"] = date.today() - relativedelta(days=15)
articles = ArticleController().read(**filter).limit(5000)
for article in articles:
try:
bgstack15