@budibase/server 2.6.13 → 2.6.14

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -144,8 +144,10 @@ function patch(ctx) {
144
144
  continue;
145
145
  combinedRow[key] = inputs[key];
146
146
  }
147
+ // need to copy the table so it can be differenced on way out
148
+ const tableClone = (0, fp_1.cloneDeep)(dbTable);
147
149
  // this returns the table and row incase they have been updated
148
- let { table, row } = (0, rowProcessor_1.inputProcessing)(ctx.user, dbTable, combinedRow);
150
+ let { table, row } = (0, rowProcessor_1.inputProcessing)(ctx.user, tableClone, combinedRow);
149
151
  const validateResult = yield utils.validate({
150
152
  row,
151
153
  table,
@@ -185,7 +187,9 @@ function save(ctx) {
185
187
  }
186
188
  // this returns the table and row incase they have been updated
187
189
  const dbTable = yield db.get(inputs.tableId);
188
- let { table, row } = (0, rowProcessor_1.inputProcessing)(ctx.user, dbTable, inputs);
190
+ // need to copy the table so it can be differenced on way out
191
+ const tableClone = (0, fp_1.cloneDeep)(dbTable);
192
+ let { table, row } = (0, rowProcessor_1.inputProcessing)(ctx.user, tableClone, inputs);
189
193
  const validateResult = yield utils.validate({
190
194
  row,
191
195
  table,