From 2797c085e51548a29b83dd6ce057ac71bde9ed0c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E0=A4=95=E0=A4=BE=E0=A4=B0=E0=A4=A4=E0=A5=8B=E0=A4=AB?= =?UTF-8?q?=E0=A5=8D=E0=A4=AB=E0=A5=87=E0=A4=B2=E0=A4=B8=E0=A5=8D=E0=A4=95?= =?UTF-8?q?=E0=A5=8D=E0=A4=B0=E0=A4=BF=E0=A4=AA=E0=A5=8D=E0=A4=9F=E2=84=A2?= Date: Mon, 19 Dec 2022 15:12:04 +0100 Subject: [PATCH] fix: Pick up credential test functions from versioned nodes as well (#4962) --- packages/core/bin/generate-known | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/packages/core/bin/generate-known b/packages/core/bin/generate-known index 55163e45a6..b6dde71d4f 100755 --- a/packages/core/bin/generate-known +++ b/packages/core/bin/generate-known @@ -29,13 +29,14 @@ const generate = async (kind) => { .sync(`dist/${kind}/**/*.${kind === 'nodes' ? 'node' : kind}.js`, { cwd: packageDir, }) - .filter((filePath) => !/[vV]\d.node\.js$/.test(filePath)) .map(loadClass) .filter((data) => !!data) .reduce((obj, { className, sourcePath, instance }) => { const name = kind === 'nodes' ? instance.description.name : instance.name; - if (name in obj) console.error('already loaded', kind, name, sourcePath); - else obj[name] = { className, sourcePath }; + if (!/[vV]\d.node\.js$/.test(sourcePath)) { + if (name in obj) console.error('already loaded', kind, name, sourcePath); + else obj[name] = { className, sourcePath }; + } if (kind === 'nodes') { const { credentials } = instance.description;