Skip to content

Commit c00ccff

Browse files
committed
Make pedigree error more discrete
1 parent 2bb4aec commit c00ccff

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

SequenceAnalysis/src/org/labkey/sequenceanalysis/SequenceAnalysisServiceImpl.java

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -425,8 +425,13 @@ else if (!StringUtils.isEmpty(pd.getFather()) && StringUtils.isEmpty(pd.getMothe
425425
boolean o2ParentOfO1 = o2.getSubjectName().equals(o1.getFather()) || o2.getSubjectName().equals(o1.getMother());
426426

427427
if (o1ParentOfO2 && o2ParentOfO1)
428-
throw new IllegalArgumentException("Pedigree records are both parents of one another: " + o1.getSubjectName() + "/" + o2.getSubjectName());
429-
else if (o1ParentOfO2)
428+
{
429+
String msg = "Pedigree records are both parents of one another: " + o1.getSubjectName() + "/" + o2.getSubjectName();
430+
_log.error(msg);
431+
throw new IllegalArgumentException(msg);
432+
}
433+
434+
if (o1ParentOfO2)
430435
return -1;
431436
else if (o2ParentOfO1)
432437
return 1;

0 commit comments

Comments
 (0)