From 3f39dfaf4c4727ee53bf0f3e374b9eba7149385b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dominique=20J=C3=A4ggi?= Date: Wed, 18 Dec 2024 10:08:59 +0100 Subject: [PATCH] chore: remove obsolete variables --- .../src/v2/models/base/reference.js | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/packages/spacecat-shared-data-access/src/v2/models/base/reference.js b/packages/spacecat-shared-data-access/src/v2/models/base/reference.js index 67d7a3a0..0e2519eb 100644 --- a/packages/spacecat-shared-data-access/src/v2/models/base/reference.js +++ b/packages/spacecat-shared-data-access/src/v2/models/base/reference.js @@ -131,13 +131,10 @@ class Reference { break; } - const prefix = `${baseMethodName}By`; - const targetIdName = entityNameToIdName(target); - for (let i = 1; i <= sortKeys.length; i += 1) { const subset = sortKeys.slice(0, i); accessorConfigs.push({ - name: keyNamesToMethodName(subset, prefix, [targetIdName]), + name: keyNamesToMethodName(subset, `${baseMethodName}By`), requiredKeys: subset, all: true, foreignKey: { name: foreignKeyName, value: foreignKeyValue },