make digest sending a hourly cron job

This commit is contained in:
Andrew Dolgov 2025-05-02 13:17:20 +03:00
parent 44b5b33f3d
commit 36f60b51d7
No known key found for this signature in database
GPG Key ID: 1A56B4FA25D4AF2A

View File

@ -285,9 +285,6 @@ class RSSUtils {
self::housekeeping_user($owner_uid); self::housekeeping_user($owner_uid);
} }
// Send feed digests by email if needed.
Digest::send_headlines_digests();
return $nf; return $nf;
} }
@ -1775,6 +1772,14 @@ class RSSUtils {
return 0; return 0;
} }
); );
PluginHost::getInstance()->add_scheduled_task('send_headlines_digests', '@hourly',
function() {
Digest::send_headlines_digests();
return 0;
}
);
} }
static function housekeeping_common(): void { static function housekeeping_common(): void {