Skip to content

Commit

Permalink
Handle missing ReferencedInstanceSequence (#47)
Browse files Browse the repository at this point in the history
  • Loading branch information
paulineribeyre authored Apr 22, 2022
1 parent d1b5636 commit b480d60
Showing 1 changed file with 11 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,16 +21,18 @@ const getReferencedSeriesSequence = instance => {
const referencedInstanceSequenceRaw = referencedSeries['0008114A'];
const referencedInstanceSequence = [];

referencedInstanceSequenceRaw.Value.forEach(referencedInstance => {
referencedInstanceSequence.push({
referencedSOPClassUID: DICOMWeb.getString(
referencedInstance['00081150']
),
referencedSOPInstanceUID: DICOMWeb.getString(
referencedInstance['00081155']
),
if (referencedInstanceSequenceRaw) {
referencedInstanceSequenceRaw.Value.forEach(referencedInstance => {
referencedInstanceSequence.push({
referencedSOPClassUID: DICOMWeb.getString(
referencedInstance['00081150']
),
referencedSOPInstanceUID: DICOMWeb.getString(
referencedInstance['00081155']
),
});
});
});
}

referencedSeriesSequence.push({
referencedSeriesInstanceUID,
Expand Down

0 comments on commit b480d60

Please sign in to comment.