Fix NPE from flagTransform
[simantics/platform.git] / bundles / org.simantics.diagram / src / org / simantics / diagram / function / All.java
index 6cd4c542f106afe53d4d80a774f4e9ace4e90e28..5bb793f7df39b6147ce72511d48664d9ba94ec95 100644 (file)
@@ -95,6 +95,8 @@ public class All {
 
                Resource flag = context.element;
                Resource runtimeDiagram = context.runtime;
+               if (runtimeDiagram == null)
+                       return flagTransformImpl(graph, converter, context);
 
                Resource diagram = graph.getPossibleObject(runtimeDiagram, DIA.RuntimeDiagram_HasConfiguration);
                if (diagram == null)