From bb5971bd827026daa06e2988d4b1d58c6c35c28f Mon Sep 17 00:00:00 2001 From: Peter Clement Date: Fri, 27 Aug 2021 14:10:19 +0100 Subject: [PATCH] change index definition --- packages/server/src/api/controllers/row/utils.js | 2 +- packages/server/src/db/views/staticViews.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/server/src/api/controllers/row/utils.js b/packages/server/src/api/controllers/row/utils.js index 9a518ff023..cb9a5e166c 100644 --- a/packages/server/src/api/controllers/row/utils.js +++ b/packages/server/src/api/controllers/row/utils.js @@ -66,7 +66,7 @@ exports.validate = async ({ appId, tableId, row, table }) => { } let res - // Validate.js doesn't seem to handle array of array very well + // Validate.js doesn't seem to handle array if (table.schema[fieldName].type === FieldTypes.ARRAY) { row[fieldName].map(val => { if (!constraints.inclusion.includes(val)) { diff --git a/packages/server/src/db/views/staticViews.js b/packages/server/src/db/views/staticViews.js index 764b8f03c8..6e52e9699c 100644 --- a/packages/server/src/db/views/staticViews.js +++ b/packages/server/src/db/views/staticViews.js @@ -102,7 +102,7 @@ exports.createAllSearchIndex = async appId => { if (Array.isArray(input[key])) { for (let val in input[key]) { // eslint-disable-next-line no-undef - index(`${idxKey}`, input[key][val], { + index(idxKey, input[key][val], { store: true, }) }