diff --git a/src/main/java/org/mskcc/smile/service/impl/CmoLabelGeneratorServiceImpl.java b/src/main/java/org/mskcc/smile/service/impl/CmoLabelGeneratorServiceImpl.java index 7381a0f..53bd079 100644 --- a/src/main/java/org/mskcc/smile/service/impl/CmoLabelGeneratorServiceImpl.java +++ b/src/main/java/org/mskcc/smile/service/impl/CmoLabelGeneratorServiceImpl.java @@ -462,6 +462,10 @@ private Integer getNextSampleIncrement(List samples) { // to prevent accidentally giving samples the same counter Integer maxIncrement = 0; for (SampleMetadata sample : samples) { + // skip samples without a defined cmo sample label + if (StringUtils.isBlank(sample.getCmoSampleName())) { + continue; + } // skip cell line samples if (CMO_CELLLINE_ID_REGEX.matcher(sample.getCmoSampleName()).find()) { continue;