updates
This commit is contained in:
@@ -81,6 +81,11 @@ const notificationService = {
|
||||
skip?: number;
|
||||
limit?: number;
|
||||
}) => {
|
||||
// Don't make API call if user is not authenticated
|
||||
const token = localStorage.getItem('token');
|
||||
if (!token) {
|
||||
throw new Error('Not authenticated');
|
||||
}
|
||||
return apiClient.get<{ status: string; data: Notification[] }>('/notifications/my-notifications', { params });
|
||||
},
|
||||
|
||||
|
||||
Reference in New Issue
Block a user