Handling invalid error codes