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

Fix onUpdate when PK is of type Identity #25

Merged
merged 1 commit into from
Oct 6, 2023
Merged

Conversation

drogus
Copy link
Collaborator

@drogus drogus commented Oct 2, 2023

Description of Changes

When the primary key is of type Identity we were still doing === comparison by using the Map data structure. This commit introduces a different data structure called OperationsMap which can also use isEqual to compare keys if isEqual function is available

API

  • This is an API breaking change to the SDK

If the API is breaking, please state below what will break

Requires SpacetimeDB PRs

List any PRs here that are required for this SDK change to work

When the primary key is of type Identity we were still doing ===
comparison by using the Map data structure. This commit introduces a
different data structure called OperationsMap which can also use isEqual
to compare keys if isEqual function is available
Copy link
Contributor

@gefjon gefjon left a comment

Choose a reason for hiding this comment

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

Love the tests!

@drogus drogus merged commit a99c6eb into main Oct 6, 2023
2 checks passed
@drogus drogus deleted the fix-identity-comparison branch October 6, 2023 18:42
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