Skip to content

Commit

Permalink
fix missing dependencies in modeldescription fmi3
Browse files Browse the repository at this point in the history
  • Loading branch information
lausdahl committed Jun 13, 2024
1 parent faa4edd commit 7bd1690
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -284,7 +284,7 @@ class Fmi3ModelDescription : ModelDescription {
return Fmi3ModelStructureElement(
valueOf(node.nodeName),
node.attributes.getNamedItem("valueReference").nodeValue.toUInt(),
node.attributes.getNamedItem("dependencies")?.nodeValue?.split(" ")
node.attributes.getNamedItem("dependencies")?.nodeValue?.split(" ")?.filter { value->value.trim().length>0 }
?.map { value -> value.toUInt() },
(node.attributes.getNamedItem("dependenciesKind")?.nodeValue ?: "").let { dependencyKinds ->
if (dependencyKinds.isEmpty()) null else dependencyKinds.split(" ")
Expand Down

0 comments on commit 7bd1690

Please sign in to comment.