Skip to content

Commit 72cdc37

Browse files
committed
Fix rdps011 failing test
1 parent af9bbc7 commit 72cdc37

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

dash/dash-renderer/src/persistence.js

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -318,7 +318,14 @@ export function recordUiEdit(layout, newProps, dispatch) {
318318
persisted_props,
319319
persistence_type
320320
} = getProps(layout);
321-
if (!canPersist || !persistence) {
321+
322+
// if the "persistence" property is changed as a callback output,
323+
// skip the persistence storage overwriting.
324+
const isPersistenceMismatch =
325+
newProps?.persistence !== undefined &&
326+
newProps.persistence !== persistence;
327+
328+
if (!canPersist || !persistence || isPersistenceMismatch) {
322329
return;
323330
}
324331

0 commit comments

Comments
 (0)