Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

isDataAvailableForKey should be public to easier to check data available #1595

Closed
wants to merge 5 commits into from

Conversation

kennic
Copy link
Contributor

@kennic kennic commented Jan 18, 2021

… so you don't need to fetch all data to get a certain data.
Sometimes the data of a user is very long but we just need to get the "username" which is already fetched.
This PR also avoid crashing when we try to get data from key which is not fetched. It should returns nil.

So we could check or get data by either ways:

if user.isDataAvailable(forKey: "username") {
 // ok
}

or

if let username = user["username"] {
// username is available
}
else {
// username is unavailable, please fetch it
}

Copy link

@stephanboner stephanboner left a comment

Choose a reason for hiding this comment

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

Looks good to me in general but why did you include the change in ParseUI into this PR? Is this on purpose?

@kennic
Copy link
Contributor Author

kennic commented Jan 27, 2021

Looks good to me in general but why did you include the change in ParseUI into this PR? Is this on purpose?

It's on purpose, it's just a minor fix to silent the "variable not used" warning

Copy link

@stephanboner stephanboner left a comment

Choose a reason for hiding this comment

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

Well then it looks good to me

@stale
Copy link

stale bot commented Jun 11, 2021

This issue has been automatically marked as stale because it has not had recent activity. If you believe it should stay open, please let us know! As always, we encourage contributions, check out the Contributing Guide

@stale stale bot added the Stale label Jun 11, 2021
@stale stale bot closed this Jul 13, 2021
@cbaker6 cbaker6 reopened this Oct 11, 2021
@stale stale bot removed the Stale label Oct 11, 2021
@@ -213,7 +213,7 @@ - (void)layoutSubviews {
frame.origin.y = currentY + loginButtonTopInset;
_signUpButton.frame = frame;

currentY = CGRectGetMaxY(frame);

Choose a reason for hiding this comment

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

Why is this being kept commented though?

@mtrezza
Copy link
Member

mtrezza commented Oct 24, 2023

Closing a superseded by #1756

@mtrezza mtrezza closed this Oct 24, 2023
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.

5 participants