Make store wrapper more resilient

This commit is contained in:
crschnick 2024-07-01 15:08:01 +00:00
parent 0620fe1d2a
commit e26240ac1f

View file

@ -151,7 +151,7 @@ public class StoreEntryWrapper {
summary.setValue(null);
} else {
try {
summary.setValue(entry.getProvider().summaryString(this));
summary.setValue(entry.getProvider() != null ? entry.getProvider().summaryString(this) : null);
} catch (Exception ex) {
// Summary creation might fail or have a bug
ErrorEvent.fromThrowable(ex).handle();
@ -162,6 +162,7 @@ public class StoreEntryWrapper {
actionProviders.clear();
defaultActionProvider.setValue(null);
} else {
try {
var defaultProvider = ActionProvider.ALL.stream()
.filter(e -> entry.getStore() != null
&& e.getDefaultDataStoreCallSite() != null
@ -173,7 +174,6 @@ public class StoreEntryWrapper {
.orElse(null);
this.defaultActionProvider.setValue(defaultProvider);
try {
var newProviders = ActionProvider.ALL.stream()
.filter(dataStoreActionProvider -> {
return showActionProvider(dataStoreActionProvider);