diff --git a/app/client/components/RecordLayout.js b/app/client/components/RecordLayout.js index 178e62da..49a03581 100644 --- a/app/client/components/RecordLayout.js +++ b/app/client/components/RecordLayout.js @@ -254,7 +254,9 @@ RecordLayout.prototype.saveLayoutSpec = async function(layoutSpec) { // with items which require new columns first. let callbacks = addedCallbacks.concat(hiddenCallbacks); let positions = addedPositions.concat(hiddenPositions); - let addActions = gutil.arrayRepeat(addColNum, addColAction); + + // Use separate copies of addColAction, since sendTableActions modified each in-place. + let addActions = gutil.arrayRepeat(addColNum, 0).map(() => addColAction.slice()); await docData.bundleActions('Updating record layout.', () => { return Promise.try(() => {