diff --git a/src/pages/notifications/notifications.js b/src/pages/notifications/notifications.js index 568f9195ca19f3c146fc3189168ff58e02d6a184..d57ddc1a3a9e8accd0dcf10a1a006aaee0152e07 100644 --- a/src/pages/notifications/notifications.js +++ b/src/pages/notifications/notifications.js @@ -47,6 +47,7 @@ const NotificationsPage = () => { try { const response = await fetch(`${baseUrl}/notification/delete/${notificationId}`, { headers: { + method: 'DELETE', Authorization: `Bearer ${localStorage.getItem("token")}`, }, }); @@ -77,7 +78,8 @@ const NotificationsPage = () => { const clearAllNotifications = async () => { // make a request to the notifications microservice to clear all notifications try { - const response = await fetch(`${baseUrl}/notification/delete/all`, { + const response = await fetch(`${baseUrl}/notification/delete-all`, { + method: 'DELETE', headers: { Authorization: `Bearer ${localStorage.getItem("token")}`, },