Added new error code and removed unused function.