Skip to content

Callback results refactor#260

Merged
jakub-grzesiowski merged 9 commits intomasterfrom
callback-results-refactor
Jul 31, 2025
Merged

Callback results refactor#260
jakub-grzesiowski merged 9 commits intomasterfrom
callback-results-refactor

Conversation

@jakub-grzesiowski
Copy link
Contributor

fix: added MembershipMetadata container to PNObjectEventResult

Added MembershipMetadata container inside PNObjectEventResult to correctly parse and forward data when object event type is "membership"

fix: changed UserMetadata from object to Dictionary<string, object>

Fixed issue where some result objects like PNMessageResult had UserMetadata declared as an object instead of the standard Dictionary<string, object> format for metadata

@pubnub-ops-terraform
Copy link

pubnub-ops-terraform commented Jul 29, 2025

🎉 Snyk checks have passed. No issues have been found so far.

security/snyk check is complete. No issues have been found. (View Details)

license/snyk check is complete. No issues have been found. (View Details)

Copy link
Contributor

@mohitpubnub mohitpubnub left a comment

Choose a reason for hiding this comment

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

LGTM!

}
public string Event { get; internal set; }
public string Type { get; internal set; }
public string Event { get; internal set; } = ""; //values = set/delete for uuid/channel/UuidAssociation/ChannelAssociation
Copy link
Contributor

Choose a reason for hiding this comment

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

👍🏻


public long Timetoken { get; internal set; }
public object UserMetadata { get; internal set; }
public Dictionary<string, object> UserMetadata { get; internal set; }
Copy link
Contributor

Choose a reason for hiding this comment

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

👍🏻

Assert.IsNotNull(eventResult.MembershipMetadata, "eventResult.MembershipMetadata should not be null");
Assert.AreEqual(eventResult.MembershipMetadata.Channel, channelMetadataId, "Wrong Channel ID in object event result");
Assert.AreEqual(eventResult.MembershipMetadata.Uuid, uuidMetadataId, "Wrong User ID in object event result");
Assert.AreEqual(eventResult.MembershipMetadata.Status, "active", "Wrong Status in object event result");
Copy link
Contributor

Choose a reason for hiding this comment

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

👍🏻

@jakub-grzesiowski
Copy link
Contributor Author

@pubnub-release-bot release as v7.4.1.0

@jakub-grzesiowski jakub-grzesiowski merged commit 5b05902 into master Jul 31, 2025
9 of 11 checks passed
@jakub-grzesiowski jakub-grzesiowski deleted the callback-results-refactor branch July 31, 2025 10:27
@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.

4 participants