Skip to content

Commit

Permalink
Merge pull request #2989 from ControlSystemStudio/CSSTUDIO-2306
Browse files Browse the repository at this point in the history
Add null check when restoring snapshot containing disconnected items
  • Loading branch information
shroffk authored Mar 25, 2024
2 parents c5f403f + 94a8088 commit c9fef61
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -353,7 +353,9 @@ public void restore(Snapshot snapshot, Consumer<List<String>> completion) {
for (SnapshotItem entry : snapshot.getSnapshotData().getSnapshotItems()) {
TableEntry e = tableEntryItems.get(getPVKey(entry.getConfigPv().getPvName(), entry.getConfigPv().isReadOnly()));

boolean restorable = e.selectedProperty().get() && !e.readOnlyProperty().get() &&
boolean restorable = e.selectedProperty().get() &&
!e.readOnlyProperty().get() &&
entry.getValue() != null &&
!entry.getValue().equals(VNoData.INSTANCE);

if (restorable) {
Expand Down

0 comments on commit c9fef61

Please sign in to comment.