Added Better Error Handling On Authentication Failure