Jake Vanderwerf
2025-11-04 42fa8304ddb811b0f725f245130f70c0f5e86a6c
inc/managers/NotificationManager.php
@@ -139,7 +139,7 @@
     */
    public function __construct()
    {
        $this->cache = new CacheManager('notifications', WEEK_IN_SECONDS); // 1 week cache
        $this->cache = CacheManager::for('notifications', WEEK_IN_SECONDS);
        // Add filter for bulk operation handling
        add_filter(BASE . 'handle_bulk_operation', [ $this, 'processOperation' ], 10, 3);
@@ -1095,7 +1095,7 @@
        }
        $content = '';
        $cache   = new CacheManager('digest_content', HOUR_IN_SECONDS * 6); // Cache for 6 hours
        $cache   = CacheManager::for('digest_content', HOUR_IN_SECONDS * 6); // Cache for 6 hours
        // Group updates by artist
        $updates_by_artist = [];
@@ -1630,8 +1630,9 @@
     */
    protected function clearNotificationCache(int $user_id):void
    {
        $this->cache->invalidate("user_{$user_id}_notifications_", 'notifications_' . $user_id);
        $this->cache->invalidate("user_{$user_id}_content_notifications_", 'notifications_' . $user_id);
        $this->cache->delete("user_{$user_id}_notifications_", 'notifications_' . $user_id);
        $this->cache->delete("user_{$user_id}_content_notifications_", 'notifications_' . $user_id);
    }
    /**