Express middleware for handling and formatting errors using http-error-kit. Ensures structured error responses with correct status codes.