fix(2fa): static import for @clocklimited/payload-2fa and @payload-config alias to prevent webpack runtime error

This commit is contained in:
2026-10-12 12:47:28 +02:00
parent a3938cacd9
commit 13d669b757
7 changed files with 11 additions and 11 deletions
+2 -2
View File
@@ -76,8 +76,8 @@ export const ipalKit = (options: IpalOptions): Plugin => {
// optional peer dependency at build time (it isn't in the plugin's own
// node_modules). Avoids TS2307 without @ts-expect-error; the module
// exists at runtime in projects that installed it.
const pkg = '@clocklimited/payload-2fa'
const mod = (await import(pkg)) as {
// @ts-ignore
const mod = (await import('@clocklimited/payload-2fa')) as {
payloadTotp?: (opts: Record<string, unknown>) => Plugin
totpPlugin?: (opts: Record<string, unknown>) => Plugin
}