Skip to content

Fix SetUUIDMetadata when no profile, email or name is set#121

Open
luna-duclos wants to merge 2 commits intopubnub:masterfrom
luna-duclos:patch-2
Open

Fix SetUUIDMetadata when no profile, email or name is set#121
luna-duclos wants to merge 2 commits intopubnub:masterfrom
luna-duclos:patch-2

Conversation

@luna-duclos
Copy link
Copy Markdown

The REST API for SetUUIDMetadata allows those fields to be unset or null but validates that if they are set they are valid.
The Go SDK always sets those fields, resulting in calls such as this one to fail:

s.pubnubClient.SetUUIDMetadata().UUID(userInfo.EmbarkUser.ExternalID.String()).Custom(pubnubUserInfoMap).Execute()

This should work, and the way to make this work is to add the omitEmpty option

@kleewho
Copy link
Copy Markdown
Contributor

kleewho commented Feb 4, 2022

@luna-duclos Thanks for the PR. We'll look into it

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