Files
klz-cables.com/.pnpm-store/v10/files/ee/baf6fcb3d174e362cf075c6b0ada12391b9ce32f56c56b2d5875250253b5a27cc16970696acfd4891e08ea8f49a214ddf1c76437aa2ec2f1dcbcfb945ae6d5
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

28 lines
841 B
Plaintext

export const transformHasManyNumber = ({ field, locale, numberRows, ref, withinArrayOrBlockLocale })=>{
let result;
if (withinArrayOrBlockLocale) {
result = numberRows.reduce((acc, { locale, number })=>{
if (locale === withinArrayOrBlockLocale) {
if (typeof number === 'string') {
number = Number(number);
}
acc.push(number);
}
return acc;
}, []);
} else {
result = numberRows.map(({ number })=>{
if (typeof number === 'string') {
number = Number(number);
}
return number;
});
}
if (locale) {
ref[field.name][locale] = result;
} else {
ref[field.name] = result;
}
};
//# sourceMappingURL=hasManyNumber.js.map