Fixing issue discovered by test case.

This commit is contained in:
mike12345567 2022-04-26 14:58:59 +01:00
parent 194b76985c
commit 0f0290411e
2 changed files with 1 additions and 2 deletions

View File

@ -24,7 +24,7 @@ function checkAutoColumns(table, oldTable) {
if (!schema.autocolumn || schema.subtype) { if (!schema.autocolumn || schema.subtype) {
continue continue
} }
const oldSchema = oldTable.schema[key] const oldSchema = oldTable && oldTable.schema[key]
if (oldSchema && oldSchema.subtype) { if (oldSchema && oldSchema.subtype) {
table.schema[key].subtype = oldSchema.subtype table.schema[key].subtype = oldSchema.subtype
} else { } else {

View File

@ -2,7 +2,6 @@ const setup = require("./utilities")
const { basicScreen } = setup.structures const { basicScreen } = setup.structures
const { checkBuilderEndpoint, runInProd } = require("./utilities/TestFunctions") const { checkBuilderEndpoint, runInProd } = require("./utilities/TestFunctions")
const { BUILTIN_ROLE_IDS } = require("@budibase/backend-core/roles") const { BUILTIN_ROLE_IDS } = require("@budibase/backend-core/roles")
const { doInAppContext } = require("@budibase/backend-core/context")
const route = "/test" const route = "/test"