fix #6215: check for datasource when opening preferencepage
authorKatja Luther <k.luther@bgbm.org>
Wed, 23 Nov 2016 13:54:51 +0000 (14:54 +0100)
committerKatja Luther <k.luther@bgbm.org>
Wed, 23 Nov 2016 13:54:51 +0000 (14:54 +0100)
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/preference/menu/CdmPreferencePage.java

index 02ff53a0d7b0c78f38f0fe44fa31c6531b70416c..92a6941302a41bacb4e9bc3c62b13b6c93ce7b18 100644 (file)
@@ -46,8 +46,11 @@ public abstract class CdmPreferencePage extends PreferencePage implements ICdmEn
     }
 
     private void initSession() {
     }
 
     private void initSession() {
-        previousCdmEntitySession = CdmStore.getCurrentSessionManager().getActiveSession();
-        bindNullSession();
+        if (CdmStore.isActive()){
+            previousCdmEntitySession = CdmStore.getCurrentSessionManager().getActiveSession();
+            bindNullSession();
+        }
+
     }
 
     private void bindNullSession() {
     }
 
     private void bindNullSession() {