From bb1aa5c2450a306b669c2e42ceebc8be85541b71 Mon Sep 17 00:00:00 2001 From: crschnick Date: Sat, 30 Dec 2023 02:17:13 +0000 Subject: [PATCH] Allow for multiple connections with same name and fix NPE --- .../io/xpipe/app/comp/store/GuiDsStoreCreator.java | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/app/src/main/java/io/xpipe/app/comp/store/GuiDsStoreCreator.java b/app/src/main/java/io/xpipe/app/comp/store/GuiDsStoreCreator.java index 02904e854..c9c4fe6d9 100644 --- a/app/src/main/java/io/xpipe/app/comp/store/GuiDsStoreCreator.java +++ b/app/src/main/java/io/xpipe/app/comp/store/GuiDsStoreCreator.java @@ -337,7 +337,7 @@ public class GuiDsStoreCreator extends MultiStepComp.Step> { } // We didn't change anything - if (existingEntry.getStore().equals(store.getValue())) { + if (existingEntry != null && existingEntry.getStore().equals(store.getValue())) { return true; } @@ -347,15 +347,6 @@ public class GuiDsStoreCreator extends MultiStepComp.Step> { } } - if (!exists) { - if (name.getValue() != null - && DataStorage.get().getStoreEntryIfPresent(name.getValue()).isPresent()) { - messageProp.setValue("Store with name " + name.getValue() + " does already exist"); - changedSinceError.setValue(false); - return false; - } - } - if (!validator.getValue().validate()) { var msg = validator .getValue()