diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/ota/service/impl/OtaBaSjGnxtwhServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/ota/service/impl/OtaBaSjGnxtwhServiceImpl.java index 8dc9643e2..6abfcea2d 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/ota/service/impl/OtaBaSjGnxtwhServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/ota/service/impl/OtaBaSjGnxtwhServiceImpl.java @@ -141,7 +141,7 @@ public class OtaBaSjGnxtwhServiceImpl extends ServiceImpl oldYjbbList = otaBaSjSjxtbh.stream().map(OtaBaSjSjxtbh::getYjbb).distinct().collect(Collectors.toList()); List oldTempFileNameList = new ArrayList<>(); oldYjbbList.forEach(sjSjxtbh -> { - oldTempFileNameList.add(sjSjxtbh.replaceAll("见","") + ".docx"); + if (StringUtils.isNotEmpty(sjSjxtbh)) { + oldTempFileNameList.add(sjSjxtbh.replaceAll("见", "") + ".docx"); + } }); int tempFileIndex = 1; String tempFilePath = uploadPath + "tempFile" + "/" + otaId; File tempFile = new File(tempFilePath); - if(!tempFile.exists()){ + if (!tempFile.exists()) { tempFile.mkdirs(); } List tempFileNames = new ArrayList<>();