- aggiunto componenti per Home Template... ma ancora da provare

- sistemato catprods
- Sistemato menu
This commit is contained in:
Surya Paolo
2025-09-22 19:09:02 +02:00
parent 4a05ddee50
commit 08cf4b6d9f
31 changed files with 475 additions and 31 deletions

View File

@@ -0,0 +1,13 @@
// @ts-check
function notFound(_req, res) {
res.status(404).json({ message: 'Not Found' });
}
function errorHandler(err, _req, res, _next) {
const status = err.status || 500;
const message = err.message || 'Server Error';
if (status >= 500) console.error(err);
res.status(status).json({ message });
}
module.exports = { notFound, errorHandler };