Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@a8m
Copy link
Member

@a8m a8m commented Oct 5, 2021

Also, for some reason, the TimeMixin.UpdateTime was an immutable field, but this was incorrect because the codegen just skipped generating update setters for it, and it was still get updated by the UpdateDefault modifier. Removing the Immutable modifier allows users to set this field explicitly.

Fixed #2000

@a8m a8m force-pushed the upsert/immutable-fields branch 2 times, most recently from 8232c87 to 78b88d2 Compare October 5, 2021 19:34
@masseelch
Copy link
Collaborator

I'll have a look tomorrow.

Copy link
Collaborator

@masseelch masseelch left a comment

Choose a reason for hiding this comment

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

LGTM

As a reminder: docs are missing ;-)

@a8m a8m force-pushed the upsert/immutable-fields branch from 78b88d2 to 895187a Compare October 7, 2021 18:33
Also, for some reason, the TimeMixin.UpdateTime was an immutable field,
but this was incorrent, because the codegen just skip generating
update setters to it. Removing the Immutable modifier allows users
to set this field explicitly.
@a8m a8m force-pushed the upsert/immutable-fields branch from 895187a to 82c7811 Compare October 8, 2021 05:13
@a8m a8m merged commit 9e80963 into master Oct 8, 2021
@a8m a8m deleted the upsert/immutable-fields branch October 8, 2021 05:20
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.

Upserts can cause Immutable Fields to Mutate

4 participants