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 Locals need to be shallow cloned. #22

Merged
merged 1 commit into from
Jul 20, 2024
Merged

Conversation

jho406
Copy link
Contributor

@jho406 jho406 commented Jul 19, 2024

Resolves #20. prop_template prebuilds an array of options before handling it off to handle_collection to build. I recall this being somewhat related to faster collection rendering. Unfortunately, the trade off is that we have to be cognizant of how we mutate deeply nested options as those can be the same object. In this case, I missed a required clone on locals.

@jho406
Copy link
Contributor Author

jho406 commented Jul 19, 2024

@kortirso this should fix the issue you're having. Would you like me to add you as co-author as I used your reproduction branch? If so, which email would you like me to use?

Let me know, i can push out a release same day.

@kortirso
Copy link
Contributor

@kortirso this should fix the issue you're having. Would you like me to add you as co-author as I used your reproduction branch? If so, which email would you like me to use?

Let me know, i can push out a release same day.

hi, @jho406 this solution totally fixes everything, thank you

@kortirso
Copy link
Contributor

@kortirso this should fix the issue you're having. Would you like me to add you as co-author as I used your reproduction branch? If so, which email would you like me to use?

Let me know, i can push out a release same day.

I can make PR with test, so there will be some kind of history :)

@kortirso
Copy link
Contributor

#24

Resolves #20. `prop_template` prebuilds an array of options before
handling it off to handle_collection to build. I recall this being
somewhat related to faster collection rendering. Unfortunately,
the trade off is that we have to be cognizant of how we mutate deeply
nested options as those can be the same object. In this case, I missed
a required clone on locals.
@jho406 jho406 force-pushed the fix-options-not-being-cloned branch from 155d99b to f19fc55 Compare July 20, 2024 04:04
@jho406 jho406 merged commit 890bffb into main Jul 20, 2024
24 checks passed
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.

Issue with rendering array with locals
2 participants