diff --git a/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/FhirVersionEnum.java b/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/FhirVersionEnum.java index 55082c59dd6..b75bcb55e30 100644 --- a/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/FhirVersionEnum.java +++ b/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/FhirVersionEnum.java @@ -309,6 +309,8 @@ public enum FhirVersionEnum { return FhirVersionEnum.DSTU3; case "R4": return FhirVersionEnum.R4; + case "R4B": + return FhirVersionEnum.R4B; case "R5": return FhirVersionEnum.R5; } diff --git a/hapi-fhir-base/src/test/java/ca/uhn/fhir/context/FhirVersionEnumTest.java b/hapi-fhir-base/src/test/java/ca/uhn/fhir/context/FhirVersionEnumTest.java index 8b3926f9f44..c1e1f49a3ce 100644 --- a/hapi-fhir-base/src/test/java/ca/uhn/fhir/context/FhirVersionEnumTest.java +++ b/hapi-fhir-base/src/test/java/ca/uhn/fhir/context/FhirVersionEnumTest.java @@ -19,8 +19,11 @@ public class FhirVersionEnumTest { assertEquals(FhirVersionEnum.R4, FhirVersionEnum.forVersionString("4.0.0")); assertEquals(FhirVersionEnum.R4, FhirVersionEnum.forVersionString("4.0.1")); assertEquals(FhirVersionEnum.R4, FhirVersionEnum.forVersionString("R4")); + assertEquals(FhirVersionEnum.R4B, FhirVersionEnum.forVersionString("R4B")); + assertEquals(FhirVersionEnum.R4B, FhirVersionEnum.forVersionString("4.3.0")); assertEquals(FhirVersionEnum.R5, FhirVersionEnum.forVersionString("R5")); + } diff --git a/hapi-fhir-docs/src/main/resources/ca/uhn/hapi/fhir/changelog/6_3_0/4291-r4b-package-install.yaml b/hapi-fhir-docs/src/main/resources/ca/uhn/hapi/fhir/changelog/6_3_0/4291-r4b-package-install.yaml new file mode 100644 index 00000000000..c15d2742094 --- /dev/null +++ b/hapi-fhir-docs/src/main/resources/ca/uhn/hapi/fhir/changelog/6_3_0/4291-r4b-package-install.yaml @@ -0,0 +1,5 @@ +--- +type: add +issue: 4291 +title: "The NPM package installer did not support installing on R4B repositories. Thanks to Jens Kristian Villadsen + for the pull request!" diff --git a/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/packages/PackageInstallerSvcImpl.java b/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/packages/PackageInstallerSvcImpl.java index 5918f00accf..d4343d1a9a6 100644 --- a/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/packages/PackageInstallerSvcImpl.java +++ b/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/packages/PackageInstallerSvcImpl.java @@ -128,6 +128,7 @@ public class PackageInstallerSvcImpl implements IPackageInstallerSvc { public void initialize() { switch (myFhirContext.getVersion().getVersion()) { case R5: + case R4B: case R4: case DSTU3: break;