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

20 lines
627 B
Plaintext

import { extractJWT, isolateObjectProperty, meOperation } from 'payload';
export function me(collection) {
async function resolver(_, args, context) {
const currentToken = extractJWT(context.req);
const options = {
collection,
currentToken,
depth: 0,
req: isolateObjectProperty(context.req, 'transactionID')
};
const result = await meOperation(options);
if (collection.config.auth.removeTokenFromResponses) {
delete result.token;
}
return result;
}
return resolver;
}
//# sourceMappingURL=me.js.map