Files
klz-cables.com/.pnpm-store/v10/files/0a/acd92655fb827307b2f80a0c9e19cb3f23bc3d2c674bdff5f4c42fc5bd38f3323cb90f970d5918d453180f9e60ebde9b1a0c31298a8ef2254aabadab713b80
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

1 line
2.7 KiB
Plaintext

{"version":3,"file":"eventProcessors.js","sources":["../../src/eventProcessors.ts"],"sourcesContent":["import { DEBUG_BUILD } from './debug-build';\nimport type { Event, EventHint } from './types-hoist/event';\nimport type { EventProcessor } from './types-hoist/eventprocessor';\nimport { debug } from './utils/debug-logger';\nimport { isThenable } from './utils/is';\nimport { rejectedSyncPromise, resolvedSyncPromise } from './utils/syncpromise';\n\n/**\n * Process an array of event processors, returning the processed event (or `null` if the event was dropped).\n */\nexport function notifyEventProcessors(\n processors: EventProcessor[],\n event: Event | null,\n hint: EventHint,\n index: number = 0,\n): PromiseLike<Event | null> {\n try {\n const result = _notifyEventProcessors(event, hint, processors, index);\n return isThenable(result) ? result : resolvedSyncPromise(result);\n } catch (error) {\n return rejectedSyncPromise(error);\n }\n}\n\nfunction _notifyEventProcessors(\n event: Event | null,\n hint: EventHint,\n processors: EventProcessor[],\n index: number,\n): Event | null | PromiseLike<Event | null> {\n const processor = processors[index];\n\n if (!event || !processor) {\n return event;\n }\n\n const result = processor({ ...event }, hint);\n\n DEBUG_BUILD && result === null && debug.log(`Event processor \"${processor.id || '?'}\" dropped event`);\n\n if (isThenable(result)) {\n return result.then(final => _notifyEventProcessors(final, hint, processors, index + 1));\n }\n\n return _notifyEventProc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