From 696f060da34d420de98c3676d02e0187027ee257 Mon Sep 17 00:00:00 2001 From: Grahame Grieve Date: Fri, 21 Apr 2023 12:23:37 +0800 Subject: [PATCH] Remove wrong id from generated value sets --- .../org/hl7/fhir/r5/terminologies/ValueSetExpanderSimple.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/org.hl7.fhir.r5/src/main/java/org/hl7/fhir/r5/terminologies/ValueSetExpanderSimple.java b/org.hl7.fhir.r5/src/main/java/org/hl7/fhir/r5/terminologies/ValueSetExpanderSimple.java index de8bda792..ac4669210 100644 --- a/org.hl7.fhir.r5/src/main/java/org/hl7/fhir/r5/terminologies/ValueSetExpanderSimple.java +++ b/org.hl7.fhir.r5/src/main/java/org/hl7/fhir/r5/terminologies/ValueSetExpanderSimple.java @@ -406,7 +406,7 @@ public class ValueSetExpanderSimple extends ValueSetWorker implements ValueSetEx ValueSetExpansionContainsComponent np = addCode(focus.getSystem(), focus.getCode(), focus.getDisplay(), vsSrc.getLanguage(), parent, convert(focus.getDesignation()), expParams, focus.getAbstract(), focus.getInactive(), focus.getExtensionString(ToolingExtensions.EXT_DEFINITION), filters, noInactive, false, vsProps, null, focus.getProperty(), null, focus.getExtension()); for (ValueSetExpansionContainsComponent c : focus.getContains()) - addCodeAndDescendents(focus, np, expParams, filters, noInactive, vsProps, vsSrc); + addCodeAndDescendents(c, np, expParams, filters, noInactive, vsProps, vsSrc); } private List convert(List designations) { @@ -542,6 +542,7 @@ public class ValueSetExpanderSimple extends ValueSetWorker implements ValueSetEx expParams = makeDefaultExpansion(); source.checkNoModifiers("ValueSet", "expanding"); focus = source.copy(); + focus.setIdBase(null); focus.setExpansion(new ValueSet.ValueSetExpansionComponent()); focus.getExpansion().setTimestampElement(DateTimeType.now()); focus.getExpansion().setIdentifier(Factory.createUUID());