From: Jani Mäkinen Date: Tue, 28 May 2019 09:36:07 +0000 (+0300) Subject: generateProposition uses component type name X-Git-Tag: v1.43.0~136^2~151 X-Git-Url: https://gerrit.simantics.org/r/gitweb?a=commitdiff_plain;h=refs%2Fchanges%2F09%2F2909%2F1;p=simantics%2Fplatform.git generateProposition uses component type name gitlab #299 Change-Id: Iee27e31d6f8b954ffedc6f31817669dd06ba0a9d --- diff --git a/bundles/org.simantics.modeling/src/org/simantics/modeling/services/ComponentNamingUtil.java b/bundles/org.simantics.modeling/src/org/simantics/modeling/services/ComponentNamingUtil.java index fc629bdb0..387b3a41a 100644 --- a/bundles/org.simantics.modeling/src/org/simantics/modeling/services/ComponentNamingUtil.java +++ b/bundles/org.simantics.modeling/src/org/simantics/modeling/services/ComponentNamingUtil.java @@ -189,7 +189,7 @@ public final class ComponentNamingUtil { if (containerGeneratedNamePrefix != null) proposition.append(containerGeneratedNamePrefix); String componentPrefix = graph.getPossibleRelatedValue(componentType, L0X.HasGeneratedNamePrefix, Bindings.STRING); - if (componentPrefix == null) { + if (componentPrefix == null || "".equals(componentPrefix)) { Layer0 L0 = Layer0.getInstance(graph); componentPrefix = graph.getPossibleRelatedValue(componentType, L0.HasName); if (componentPrefix == null)