forked from ryanmwangi/CalMerger
update the name of the saved separate JSON file
This commit is contained in:
parent
8531b4ce2b
commit
bbd93317a1
|
@ -103,10 +103,10 @@ END:VEVENT
|
|||
icalString += `END:VCALENDAR`;
|
||||
fs.writeFileSync(`${MERGED_CALENDARS_DIR}/${filename}`, icalString);
|
||||
|
||||
// Save the user input and generated ID in a separate JSON file
|
||||
// Save the user input and sanitizedLinkGroupName in a separate JSON file
|
||||
saveCalendarData(sanitizedLinkGroupName, linkGroupName, calendars);
|
||||
|
||||
res.json({ url: `${req.protocol}://${req.get('host')}/calendar/${calendarId}` });
|
||||
res.json({ url: `${req.protocol}://${req.get('host')}/calendar/${sanitizedLinkGroupName}` });
|
||||
} catch (error) {
|
||||
console.error(error);
|
||||
res.status(500).json({ error: 'Failed to merge calendars' });
|
||||
|
|
Loading…
Reference in New Issue