UNPKG

@lucidcms/core

Version:

The core of the Lucid CMS. It's responsible for spinning up the API and serving the CMS.

2 lines 562 B
import{translate as e}from"../../i18n/translate.mjs";const t=t=>{if(t.locales.length===0)throw Error(e(`server:core.config.locales.empty`));if(t.defaultLocale===void 0)throw Error(e(`server:core.config.default.locale.undefined`));if(t.locales.find(e=>e.code===t.defaultLocale)===void 0)throw Error(e(`server:core.config.default.locale.not.found`));let n=t.locales.map(e=>e.code),r=n.find((e,t)=>n.indexOf(e)!==t);if(r!==void 0)throw Error(e(`server:core.config.duplicate.locale`,{data:{code:r}}))};export{t as default}; //# sourceMappingURL=check-locales.mjs.map