fixed deploy

This commit is contained in:
Jan Prochazka 2024-11-11 13:20:04 +01:00
parent fa72d9a39f
commit 9a73eb3620

View File

@ -231,13 +231,13 @@ export function skipNamesInStructureByRegex(db: DatabaseInfo, regex: RegExp) {
export function detectChangesInPreloadedRows(oldTable: TableInfo, newTable: TableInfo): boolean {
const key =
newTable.preloadedRowsKey ||
oldTable.preloadedRowsKey ||
newTable.primaryKey?.columns?.map(x => x.columnName) ||
oldTable.primaryKey?.columns?.map(x => x.columnName);
newTable?.preloadedRowsKey ||
oldTable?.preloadedRowsKey ||
newTable?.primaryKey?.columns?.map(x => x.columnName) ||
oldTable?.primaryKey?.columns?.map(x => x.columnName);
const oldRows = oldTable?.preloadedRows || [];
const newRows = newTable?.preloadedRows || [];
const insertOnly = newTable.preloadedRowsInsertOnly || oldTable.preloadedRowsInsertOnly;
const insertOnly = newTable?.preloadedRowsInsertOnly || oldTable?.preloadedRowsInsertOnly;
if (newRows.length != oldRows.length) {
return true;