Skip to content

fix: error when saving global with versioning enabled #12778

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

Merged
merged 2 commits into from
Jun 12, 2025
Merged

Conversation

AlessioGr
Copy link
Member

@AlessioGr AlessioGr commented Jun 11, 2025

When saving a global with versioning enabled as draft, and then publishing it, the following error may appear: [16:50:35] ERROR: Could not find createdAt or updatedAt in latestVersion.version

This is due to an incorrect check to appease typescript strict mode. We shouldn't throw if version.updatedAt doesn't exist - the purpose of this logic is to add that property if it doesn't exist

@AlessioGr AlessioGr enabled auto-merge (squash) June 11, 2025 23:56
@AlessioGr AlessioGr disabled auto-merge June 12, 2025 00:02
paulpopus
paulpopus previously approved these changes Jun 12, 2025
@AlessioGr AlessioGr merged commit cf43c5c into main Jun 12, 2025
77 checks passed
@AlessioGr AlessioGr deleted the fix/logic-version branch June 12, 2025 01:39
Copy link
Contributor

🚀 This is included in version v3.43.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants