fix: preserve empty arrays in facet fields#114
Conversation
|
|
Caution Review failedThe pull request is closed. 📝 WalkthroughWalkthroughChanged two truthiness guards in createHypercertRecord to explicit Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~8 minutes Poem
🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing touches
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Pull request overview
Updates hypercert record creation to preserve empty facet arrays by switching from truthy checks to explicit !== undefined checks.
Changes:
- Preserve
shortDescriptionFacetswhen provided as an empty array by checking!== undefined. - Preserve
descriptionFacetswhen provided as an empty array by checking!== undefined.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Change truthy checks to explicit !== undefined checks for shortDescriptionFacets and descriptionFacets to ensure empty arrays are preserved as valid values. Fixes unresolved comment from PR #112 review thread #3700691486
36eacc3 to
e97a283
Compare
Change truthy checks to explicit !== undefined checks for shortDescriptionFacets and descriptionFacets to ensure empty arrays are preserved as valid values.
Fixes unresolved comment from PR #112 review thread #3700691486
Summary by CodeRabbit
✏️ Tip: You can customize this high-level summary in your review settings.
Note
Ensures facet fields are written even when empty arrays are provided.
HypercertOperationsImpl.tscreateHypercertRecord, changed checks toparams.* !== undefinedforshortDescriptionFacetsanddescriptionFacets, allowing empty arrays to be persisted instead of being skipped.Written by Cursor Bugbot for commit e97a283. This will update automatically on new commits. Configure here.