From f5f03442aa749da20cedc5d417272b25046dbf2a Mon Sep 17 00:00:00 2001 From: dotasek Date: Fri, 27 Jan 2023 11:22:37 -0500 Subject: [PATCH] Better error description --- .../validation/instance/type/StructureDefinitionValidator.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/org.hl7.fhir.validation/src/main/java/org/hl7/fhir/validation/instance/type/StructureDefinitionValidator.java b/org.hl7.fhir.validation/src/main/java/org/hl7/fhir/validation/instance/type/StructureDefinitionValidator.java index ff020330d..c932380f0 100644 --- a/org.hl7.fhir.validation/src/main/java/org/hl7/fhir/validation/instance/type/StructureDefinitionValidator.java +++ b/org.hl7.fhir.validation/src/main/java/org/hl7/fhir/validation/instance/type/StructureDefinitionValidator.java @@ -164,7 +164,7 @@ public class StructureDefinitionValidator extends BaseValidator { tc = type.getExtensionValue(ToolingExtensions.EXT_FHIR_TYPE).primitiveValue(); } if (Utilities.noString(tc) && type.hasChild("code")) { - throw new Error("WTF?"); + throw new Error("Snapshot for " + sd.getId() +" element " + path + " has type.code without a value "); // if (type.getNamedChild("code").hasExtension(" http://hl7.org/fhir/StructureDefinition/structuredefinition-json-type")) { // tc = "*"; // }