Skip to content

Context should be created on save #22#23

Open
duleorlovic wants to merge 1 commit intostate-machines:masterfrom
duleorlovic:context_based_on_save
Open

Context should be created on save #22#23
duleorlovic wants to merge 1 commit intostate-machines:masterfrom
duleorlovic:context_based_on_save

Conversation

@duleorlovic
Copy link

It seems that context is evaluated on .new instead of .save

It seems that context is evaluated on `.new` instead of `.save`
@ryanseys
Copy link

ryanseys commented Feb 8, 2024

@seuros could we get a review of this as well? This would fix a MonkeyPatch that we have been using for a while.

@ryanseys
Copy link

ryanseys commented Feb 8, 2024

Our monkeypatch is changing this line from after_initialize to before_create:

state_machine.owner_class.after_initialize do |object|

which it appears this PR is trying to do in a slightly different way?

Perhaps either / both approaches would work, but getting this fixed would be amazing :)

@seuros seuros self-assigned this Feb 9, 2024
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