Skip to content
This repository has been archived by the owner on Aug 15, 2019. It is now read-only.

fix(StudyMetadata): Gets the modality information from first series item #55

Merged
merged 2 commits into from
Jul 21, 2019
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 11 additions & 1 deletion src/classes/metadata/StudyMetadata.js
Original file line number Diff line number Diff line change
Expand Up @@ -635,7 +635,17 @@ function _getDisplaySetFromSopClassModule(
headers,
});

return plugin.getDisplaySetFromSeries(series, study, dicomWebClient, headers);
let displaySet = plugin.getDisplaySetFromSeries(
series,
study,
dicomWebClient,
headers
);
if (displaySet) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you make this if (displaySet && !displaySet.modality), so we don't overwrite what the plugin returned?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sure, I will change it here

const instance = series.getFirstInstance();
displaySet.modality = instance.getRawValue('x00080060');
}
return displaySet;
}

/**
Expand Down