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

Mc/add membership type #151

Merged
merged 7 commits into from
Jan 7, 2025
Merged

Mc/add membership type #151

merged 7 commits into from
Jan 7, 2025

Conversation

marcin-cebo
Copy link
Contributor

@marcin-cebo marcin-cebo commented Dec 19, 2024

feat: Added status and type to Membership.

@@ -110,12 +118,14 @@ data class MembershipImpl(
user,
update.custom?.value ?: custom,
Copy link
Contributor

Choose a reason for hiding this comment

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

actually I noticed an error in my code, it should be:
update.custom.let { newCustom -> if (newCustom != null) newCustom.value else custom },

and the new ones (status and type) should follow the same pattern

Copy link
Contributor Author

@marcin-cebo marcin-cebo Dec 20, 2024

Choose a reason for hiding this comment

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

What is a difference between:
update.custom?.value ?: custom,
and
update.custom.let { newCustom -> if (newCustom != null) newCustom.value else custom },
?

Comment on lines 107 to 114
includeCustom = true,
includeStatus = false,
includeType = false,
includeTotalCount = true,
includeChannel = true,
includeChannelCustom = true,
includeChannelType = true,
includeChannelStatus = false
Copy link
Contributor

Choose a reason for hiding this comment

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

we should probably set all includes to true everywhere, otherwise there's no way to get e.g. status and type for memberships, since the user can't override it

Copy link
Contributor Author

@marcin-cebo marcin-cebo Dec 20, 2024

Choose a reason for hiding this comment

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

Good point. I will check all cases where include params are needed.

@marcin-cebo marcin-cebo force-pushed the mc/addMembershipType branch from 95bbb0f to 2bcaf27 Compare January 3, 2025 12:05
@marcin-cebo
Copy link
Contributor Author

@pubnub-release-bot release kotlin as 0.10.0

1 similar comment
@marcin-cebo
Copy link
Contributor Author

@pubnub-release-bot release kotlin as 0.10.0

@marcin-cebo marcin-cebo merged commit 38a7729 into master Jan 7, 2025
2 checks passed
@marcin-cebo marcin-cebo deleted the mc/addMembershipType branch January 7, 2025 17:04
@pubnub-release-bot
Copy link
Contributor

🚀 Release successfully completed 🚀

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.

3 participants