Add error handling
This commit is contained in:
@@ -9,4 +9,8 @@ app.use(express.json());
|
|||||||
|
|
||||||
app.use('/v1/notes', notesRoutes);
|
app.use('/v1/notes', notesRoutes);
|
||||||
|
|
||||||
|
app.use((req, res) => {
|
||||||
|
res.status(404).json({ error: `Requested path is invalid or does not exist: ${req.method} ${req.originalUrl}` });
|
||||||
|
});
|
||||||
|
|
||||||
export default app;
|
export default app;
|
||||||
|
|||||||
@@ -22,10 +22,10 @@
|
|||||||
.main-head {
|
.main-head {
|
||||||
font-size: 5rem;
|
font-size: 5rem;
|
||||||
color: #6dd6f4;
|
color: #6dd6f4;
|
||||||
margin: 2px 0px 24px 22px;
|
margin: 6px 0px 24px 22px;
|
||||||
font-family: "Sulphur Point", sans-serif;
|
font-family: "Sulphur Point", sans-serif;
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
letter-spacing: 3px;
|
letter-spacing: 4px;
|
||||||
text-decoration: underline;
|
text-decoration: underline;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user