Fix bug for authentication with non-identity field