a little error handling
This commit is contained in:
parent
61b4a9f422
commit
381d77ac64
@ -176,6 +176,10 @@ function getUrl (req, res) {
|
|||||||
|
|
||||||
app.get('/:encoded_id', cache('15 minutes'), getUrl);
|
app.get('/:encoded_id', cache('15 minutes'), getUrl);
|
||||||
|
|
||||||
|
process.on('uncaughtException', function (err) {
|
||||||
|
console.error(err);
|
||||||
|
});
|
||||||
|
|
||||||
const server = app.listen(port, () => {
|
const server = app.listen(port, () => {
|
||||||
logger.info(`Server listening on port ${port}`);
|
logger.info(`Server listening on port ${port}`);
|
||||||
});
|
});
|
||||||
|
Loading…
x
Reference in New Issue
Block a user