Fixed and added important error codes.