Advanced error handling for express.js