diff --git a/package.json b/package.json index 5fe09cf..a26720f 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "my-weekly-todo-list", - "version": "1.62.0", + "version": "1.62.1", "description": "A web-based weekly task management application that organizes to-dos and calendar events in a single, intuitive weekly view", "main": "index.js", "scripts": { diff --git a/src/lib/outlook-calendar.ts b/src/lib/outlook-calendar.ts index 946f370..ff87bd9 100644 --- a/src/lib/outlook-calendar.ts +++ b/src/lib/outlook-calendar.ts @@ -324,7 +324,7 @@ export const updateEvent = async ( eventId: string, event: any ) => { - const response = await fetch(`${GRAPH_ENDPOINT}/me/events/${encodeURIComponent(eventId)}`, { + const response = await fetch(`${GRAPH_ENDPOINT}/me/calendars/${encodeURIComponent(calendarId)}/events/${encodeURIComponent(eventId)}`, { method: 'PATCH', headers: { 'Authorization': `Bearer ${accessToken}`, @@ -387,7 +387,7 @@ export const deleteEvent = async ( calendarId: string, eventId: string ) => { - const response = await fetch(`${GRAPH_ENDPOINT}/me/events/${encodeURIComponent(eventId)}`, { + const response = await fetch(`${GRAPH_ENDPOINT}/me/calendars/${encodeURIComponent(calendarId)}/events/${encodeURIComponent(eventId)}`, { method: 'DELETE', headers: { 'Authorization': `Bearer ${accessToken}`