fixes saving trigger and throwing an error when appdefinition is null on first load

This commit is contained in:
arpitnath 2024-04-06 17:16:57 +05:30
parent a4a033cc6f
commit 770e207af1

View file

@ -983,7 +983,7 @@ const EditorComponent = (props) => {
updateEditorState({
isUpdatingEditorStateInProcess: false,
});
} else if (!isEmpty(editingVersion)) {
} else if (!isEmpty(editingVersion) && !isEmpty(appDiffOptions) && appDefinition) {
//! The computeComponentPropertyDiff function manages the calculation of differences in table columns by requiring complete column data. Without this complete data, the resulting JSON structure may be incorrect.
const paramDiff = computeComponentPropertyDiff(appDefinitionDiff, appDefinition, appDiffOptions);
const updateDiff = computeAppDiff(paramDiff, currentPageId, appDiffOptions, currentLayout);