From f0ddeddea8fc5c18442d64adf2f6c51aca530f41 Mon Sep 17 00:00:00 2001 From: Artem Niehrieiev Date: Wed, 22 Oct 2025 09:07:43 +0000 Subject: [PATCH] fix: ensure hidden_tables is defined before checking if it's an array --- .../utils/validate-create-connection-properties-ds.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backend/src/entities/connection-properties/utils/validate-create-connection-properties-ds.ts b/backend/src/entities/connection-properties/utils/validate-create-connection-properties-ds.ts index 2262fa94e..492f3798f 100644 --- a/backend/src/entities/connection-properties/utils/validate-create-connection-properties-ds.ts +++ b/backend/src/entities/connection-properties/utils/validate-create-connection-properties-ds.ts @@ -14,7 +14,7 @@ export async function validateCreateConnectionPropertiesDs( const errors = []; const dao = getDataAccessObject(connection); const tablesInConnection = (await dao.getTablesFromDB()).map((table) => table.tableName); - if (!Array.isArray(hidden_tables)) { + if (hidden_tables && !Array.isArray(hidden_tables)) { errors.push(Messages.HIDDEN_TABLES_MUST_BE_ARRAY); } if (hidden_tables && hidden_tables.length > 0) {