Skip to content

Commit

Permalink
Add more leniency for files that don't add proper cv
Browse files Browse the repository at this point in the history
because those bad files are in the wild.
  • Loading branch information
Mailaender committed Jan 8, 2025
1 parent b937b73 commit 4c58db7
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -104,8 +104,9 @@ private void readProcessingMethod(Description description, IStandaloneMassSpectr
}
for(Object object : processingMethod.getCvParamOrUserParam()) {
if(object instanceof CvParamType cvParamType) {
if(cvParamType.getName().equals("peakProcessing")) {
if(cvParamType.getValue().equals("centroided")) {
// also support poorly standardized files
if(cvParamType.getName().toLowerCase().contains("peakprocessing")) {
if(cvParamType.getValue().toLowerCase().contains("centroid")) {
massSpectrum.setMassSpectrumType(MassSpectrumType.CENTROID);
}
}
Expand Down

0 comments on commit 4c58db7

Please sign in to comment.