-
Notifications
You must be signed in to change notification settings - Fork 9
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
Updated PubNub Js sdk containing membership type. #325
base: master
Are you sure you want to change the base?
Conversation
In KMP js implemented new Memberships and ChannelMembers methods containing possibility to specify membership type and all optional data returned by API using include parameters.
3e3b6c3
to
8b2a961
Compare
this.include = createJsObject<PubNubJs.MembershipIncludeOptions> { | ||
this.customFields = include.includeCustom | ||
this.totalCount = include.includeTotalCount | ||
this.channelFields = include.includeChannel | ||
this.customChannelFields = include.includeChannelCustom | ||
this.channelTypeField = include.includeChannelType | ||
this.channelStatusField = include.includeChannelStatus | ||
this.statusField = include.includeStatus | ||
this.typeField = include.includeType | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
perhaps we could extract this into a function like MembershipInclude.toMembershipIncludeOptions()
if it's used in a few places
this.include = createJsObject<PubNubJs.IncludeOptions> { | ||
this.totalCount = include.includeTotalCount | ||
this.customFields = include.includeCustom | ||
this.UUIDFields = include.includeUser | ||
this.customUUIDFields = include.includeUserCustom | ||
this.UUIDTypeField = include.includeUserType | ||
this.UUIDStatusField = include.includeUserStatus | ||
this.statusField = include.includeStatus | ||
this.typeField = include.includeType | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same - extract to a function?
In KMP js implemented new Memberships and ChannelMembers methods containing possibility to specify membership type and all optional data returned by API using include parameters.