From 5e9dfa9fd0c7ace212ca1f744deb31c6d0acac23 Mon Sep 17 00:00:00 2001 From: Marc Plano-Lesay Date: Sat, 3 May 2025 15:22:01 +1000 Subject: [PATCH] Properly skip notifications only when nothing has happened --- src/notifications/notification.rs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/notifications/notification.rs b/src/notifications/notification.rs index cee30d4..4f82af9 100644 --- a/src/notifications/notification.rs +++ b/src/notifications/notification.rs @@ -27,7 +27,11 @@ pub trait Notification { total_new_links: usize, ) -> bool { // Don't send notification if everything was successful but 0 links were grabbed and processed - if total_new_links == 0 && action_results.values().all(|pm| pm.failed.is_empty()) { + if total_new_links == 0 + && action_results + .values() + .all(|pm| pm.failed.is_empty() && pm.success.is_empty()) + { return false; } true