Open-source serverless enterprise CMS. Includes a headless CMS, page builder, form builder, and file manager. Easy to customize and expand. Deploys to AWS.
This PR ensures that DZ field storage doesn't create a default [] value, because it will break subsequent partial draft saving. To make this possible, we had to reduce the amount of errors being thrown by DZ field transform plugin, and instead use reasonable fallbacks. If the incoming value is not valid for storage, we simply skip it. Doing it this way ensures data consistency in the database/opensearch, and also allows us to save partial entries, where a DZ field can be null or undefined.
Changes
This PR ensures that DZ field storage doesn't create a default
[]
value, because it will break subsequent partial draft saving. To make this possible, we had to reduce the amount of errors being thrown by DZ field transform plugin, and instead use reasonable fallbacks. If the incoming value is not valid for storage, we simply skip it. Doing it this way ensures data consistency in the database/opensearch, and also allows us to save partial entries, where a DZ field can benull
orundefined
.How Has This Been Tested?
Manually, and Jest tests.