@lucidcms/core
Version:
The core of the Lucid CMS. It's responsible for spinning up the API and serving the CMS.
2 lines • 528 B
JavaScript
import{copy as e}from"../../../libs/i18n/copy.mjs";const t=t=>{try{let n={};for(let[r,i]of Object.entries(t.output)){let a=t.field.formatAiGeneratedValue(i);if(!a.success)return{error:{type:`basic`,status:502,message:a.message??e(`server:core.routes.ai.generate.error.message`)},data:void 0};n[r]=a.value}return{error:void 0,data:n}}catch{return{error:{type:`basic`,status:502,message:e(`server:core.routes.ai.generate.error.message`)},data:void 0}}};export{t as default};
//# sourceMappingURL=format-custom-field-output.mjs.map