From 1d1ff12c9b1203f401e1e72fcabc059e87aa53c1 Mon Sep 17 00:00:00 2001 From: Ryan Luu Date: Thu, 4 Jul 2024 12:43:52 +0000 Subject: [PATCH] Fix refresh --- src/instagram_to_discord.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/instagram_to_discord.py b/src/instagram_to_discord.py index 1a953d0..b07ab35 100644 --- a/src/instagram_to_discord.py +++ b/src/instagram_to_discord.py @@ -59,7 +59,7 @@ def check_for_new_posts(): posts = profile.get_posts() until = datetime.now() - since = until.replace(hour=until.second-REFRESH_INTERVAL) # Check for posts in the last hour + since = until.replace(second=until.second-REFRESH_INTERVAL) for post in takewhile(lambda p: p.date > until, dropwhile(lambda p: p.date > since, posts)): instagram_post_url = "https://instagram.com/p/" + post.shortcode + "/"