forked from ryanmwangi/CalMerger
add catch block
This commit is contained in:
parent
35deb877a3
commit
08f9f5a15d
1 changed files with 3 additions and 1 deletions
|
@ -143,8 +143,10 @@ app.get('/calendar/:name', async (req, res) => {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
} catch (error) {
|
||||||
|
console.error(error);
|
||||||
|
res.status(500).json({ error: 'Failed to retrieve calendar data.' });
|
||||||
}
|
}
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
// Serve the merged calendar file
|
// Serve the merged calendar file
|
||||||
|
|
Loading…
Add table
Reference in a new issue