Skip to content

Commit

Permalink
Attempt to fix intermittent error with transient object saving
Browse files Browse the repository at this point in the history
  • Loading branch information
mseaton committed May 6, 2024
1 parent b74e0ce commit 0f9e11e
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -234,6 +234,7 @@ protected List<Encounter> createRandomEncountersWithDiagnoses(int count, double
lastTime = obs.getObsDatetime().getTime();
}
}
Context.getEncounterService().saveEncounter(e);
encounters.add(e);
}

Expand Down Expand Up @@ -272,7 +273,6 @@ public void getUniqueDiagnoses_shouldConvergeWithLegacyImpl() throws ParseExcept
List<Encounter> encounters = createRandomEncountersWithDiagnoses(50, 0.15, 2, visit, patient, emrApiProperties.getVisitNoteEncounterType(), sampleDiagnoses);
for (Encounter e : encounters) {
visit.addEncounter(e);
Context.getEncounterService().saveEncounter(e);
}
visit = Context.getVisitService().saveVisit(visit);
VisitDomainWrapper visitDomainWrapper = factory.newVisitDomainWrapper( visit );
Expand Down

0 comments on commit 0f9e11e

Please sign in to comment.