From 756e5fde2fc1c181e9582fbb3ee73b96901b832e Mon Sep 17 00:00:00 2001 From: miteruzo Date: Sun, 1 Sep 2024 17:16:18 +0900 Subject: [PATCH] =?UTF-8?q?=E8=87=AA=E5=8B=95=20Follow=20=E3=82=92?= =?UTF-8?q?=E8=BF=BD=E5=8A=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- main.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/main.py b/main.py index 7b0d46d..7465106 100644 --- a/main.py +++ b/main.py @@ -15,9 +15,11 @@ def check_notifications ( for notification in (client.app.bsky.notification.list_notifications () .notifications): - if ((not notification.is_read) - and (notification.reason in ['mention', 'reply'])): - uris += [notification.uri] + if not notification.is_read: + if notification.reason in ['mention', 'reply']: + uris += [notification.uri] + elif notification.reason == 'follow': + client.follow (notification.ahthor.did) client.app.bsky.notification.update_seen ({ 'seen_at': last_seen_at })