Files
klz-cables.com/.pnpm-store/v10/files/a1/784a62eec8d4104fc5f749ad1189f937ac4322f473246952b6aa3f0b7ef7fcec74d74fbdbbed0fcc8746b295fb84030a973d6f4b1bd1cce081ef266016e0e2
Marc Mintel 5397309103
Some checks failed
Build & Deploy / 🔍 Prepare (push) Successful in 20s
Build & Deploy / 🧪 QA (push) Failing after 34s
Build & Deploy / 🏗️ Build (push) Has started running
Build & Deploy / 🚀 Deploy (push) Has been cancelled
Build & Deploy / 🧪 Smoke Test (push) Has been cancelled
Build & Deploy / ⚡ Lighthouse (push) Has been cancelled
Build & Deploy / 🔔 Notify (push) Has been cancelled
fix(products): fix breadcrumbs and product filtering (backport from main)
2026-02-24 16:04:21 +01:00

26 lines
967 B
Plaintext

import { APIError } from '../../../errors/index.js';
import { createLocalReq } from '../../../utilities/createLocalReq.js';
import { findOneOperation } from '../findOne.js';
export async function findOneGlobalLocal(payload, options) {
const { slug: globalSlug, data, depth, draft = false, flattenLocales, includeLockStatus, overrideAccess = true, populate, select, showHiddenFields } = options;
const globalConfig = payload.globals.config.find((config)=>config.slug === globalSlug);
if (!globalConfig) {
throw new APIError(`The global with slug ${String(globalSlug)} can't be found.`);
}
return findOneOperation({
slug: globalSlug,
data,
depth,
draft,
flattenLocales,
globalConfig,
includeLockStatus,
overrideAccess,
populate,
req: await createLocalReq(options, payload),
select,
showHiddenFields
});
}
//# sourceMappingURL=findOne.js.map