Skip to content

Authentication APIs doesn't return TokenData #3

Description

@PvtPrivate

All Login methods in User API with the ResultCallback<TokenData, OAuthError> callback doesn't actually return the TokenData object, and there is no alternate methods to get the TokenData afterwards.

The result from the HTTP response is not passed to the callback:

Result<TokenData, OAuthError> result = response.TryParseJson<TokenData, OAuthError>();
if (!result.IsError)
{
this.SetSession(result.Value);
callback.TryOk();
}
else
{
callback.TryError(result.Error);
}

Should it not be:

if (!result.IsError)
{
    this.SetSession(result.Value);
}
callback.Try(result);

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions