Skip to content

Commit

Permalink
Merge branch 'BS-288' into BS-288-deploy
Browse files Browse the repository at this point in the history
# Conflicts:
#	src/main/java/org/snomed/cdsservice/service/medication/dose/SnomedMedicationDefinedDailyDoseService.java
  • Loading branch information
manimaarans committed Nov 8, 2023
2 parents f2e2740 + 1d12553 commit 31b30e0
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -287,13 +287,13 @@ private void aggregateMedicationsBySubstance(Map<String, AggregatedMedicationsBy
try {
prescribedDailyDoseInUnitOfSubstanceStrength = getPrescribedDailyDoseInUnitOfSubstanceStrength(prescribedDailyDose, strengthValue, strengthUnit, denominatorValue, denominatorUnit);
} catch (Exception e) {
throw new ResponseStatusException(HttpStatus.PRECONDITION_FAILED, String.format("Mismatched Dose units for the medicine %s", snomedMedicationLabel), null);
throw new ResponseStatusException(HttpStatus.PRECONDITION_FAILED, String.format("Prescribed dosage could not be validated for %s. Reason: Invalid dose unit.", snomedMedicationLabel), null);
}
PrescribedDailyDose prescribedDailyDoseInUnitOfDDD;
try {
prescribedDailyDoseInUnitOfDDD = getPrescribedDailyDoseInUnitOfDDD(prescribedDailyDoseInUnitOfSubstanceStrength.getQuantity(), prescribedDailyDoseInUnitOfSubstanceStrength.getUnit(), substanceDefinedDailyDose.unit());
} catch (Exception e) {
throw new ResponseStatusException(HttpStatus.PRECONDITION_FAILED, String.format("Mismatched Dose units for the medicine %s", snomedMedicationLabel), null);
throw new ResponseStatusException(HttpStatus.PRECONDITION_FAILED, String.format("Prescribed dosage could not be validated for %s. Reason: Invalid dose unit.", snomedMedicationLabel), null);
}
AggregatedMedicationsBySubstance aggregatedMedicationsBySubstance = aggregatedMedicationsBySubstanceMap.get(substance);
if (aggregatedMedicationsBySubstance == null) {
Expand Down

0 comments on commit 31b30e0

Please sign in to comment.