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

Save History fix for new instances #1580

Conversation

clpetersonucf
Copy link
Member

A couple spots in the creator component were using references to the instId prop, which is undefined or null when a new instance is initialized. The value is never updated retroactively, so hooks that prompt the creator to reload via Save History would initialize another new instance instead of using the initExistingWidget path.

Updated a couple references to the instId prop to reference instIdRef's current value instead, and ensured that ref value is updated after the instance is saved (and a fresh instance ID is provided).

@clpetersonucf clpetersonucf marked this pull request as ready for review April 30, 2024 18:04
Copy link
Contributor

@cayb0rg cayb0rg left a comment

Choose a reason for hiding this comment

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

Not seeing any issues here, and save history now works with new instances. Nice work!

@clpetersonucf clpetersonucf merged commit 4d4819c into ucfopen:dev/10.2.0 May 3, 2024
2 checks passed
@clpetersonucf clpetersonucf deleted the issue/1510-fix-for-save-history-new-instances branch May 3, 2024 14:41
@clpetersonucf clpetersonucf mentioned this pull request May 14, 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.

2 participants