This commit is contained in:
2025-12-16 13:13:03 +01:00
parent 7d3393e1b9
commit 84f05598a6
78 changed files with 161 additions and 157 deletions

View File

@@ -5,7 +5,7 @@
*/
import type { AsyncUseCase } from '@core/shared/application';
import type { Logger } from '../../../shared/src/logging/Logger';
import type { Logger } from '@core/shared/application';
import type { Notification } from '../../domain/entities/Notification';
import type { INotificationRepository } from '../../domain/repositories/INotificationRepository';
@@ -35,7 +35,7 @@ export class GetUnreadNotificationsUseCase implements AsyncUseCase<string, Unrea
totalCount: notifications.length,
};
} catch (error) {
this.logger.error(`Failed to retrieve unread notifications for recipient ID: ${recipientId}`, error);
this.logger.error(`Failed to retrieve unread notifications for recipient ID: ${recipientId}`, error instanceof Error ? error : new Error(String(error)));
throw error;
}
}