Skip to content

Conversation

@Alex-4-Git
Copy link
Contributor

Add class GIDUserAuth to represent the outcome of a successful signIn or addScopes flow.

Add class GIDUserAuth to represent the outcome of a successful signIn or addScopes flow.
@Alex-4-Git Alex-4-Git requested review from mdmathias and petea July 5, 2022 23:41
/// An OAuth2 authorization code for the home server.
@property(nonatomic, readonly, nullable) NSString *serverAuthCode;

+ (instancetype)new NS_UNAVAILABLE;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it worth documenting here how this type is supposed to be created?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we don't need to document that. For our clients they only need to read the data inside this class. I will add unsupported here.

Copy link
Collaborator

@mdmathias mdmathias Jul 7, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think /// Unsupported. adds much. It'd be more helpful to have something like (for this and init below):

Unavailable. See the internally scoped -[GIDUserAuth_Private initWithGoogleUser:serverAuthCode:] to create an instance.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a public API. There is no benefit if we tell them how to create this instance because we don't want them to do it.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fair enough. I don't think /// Unsupported. is useful. Feel free to remove.

@Alex-4-Git Alex-4-Git requested a review from mdmathias July 7, 2022 18:07
@Alex-4-Git Alex-4-Git merged commit 10874cc into GIDGoogleUser-restructure Jul 10, 2022
Alex-4-Git added a commit that referenced this pull request Aug 3, 2022
* Create class GIDUserAuth

Add class GIDUserAuth to represent the outcome of a successful signIn or addScopes flow.
Alex-4-Git added a commit that referenced this pull request Aug 3, 2022
* Create class GIDUserAuth

Add class GIDUserAuth to represent the outcome of a successful signIn or addScopes flow.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants