فهرست منبع

过滤本地文件时,不区分tmp、.jasper等过滤项的大小写

sunyj 8 سال پیش
والد
کامیت
321b50ea1c
1فایلهای تغییر یافته به همراه1 افزوده شده و 1 حذف شده
  1. 1 1
      src/main/java/com/uas/report/service/impl/FileServiceImpl.java

+ 1 - 1
src/main/java/com/uas/report/service/impl/FileServiceImpl.java

@@ -73,7 +73,7 @@ public class FileServiceImpl implements FileService {
 				return false;
 			}
 			// 不支持查看、压缩:jasper文件、tmp路径
-			String filePath = file.getPath();
+			String filePath = file.getPath().toLowerCase();
 			if (filePath.endsWith(".jasper") || filePath.endsWith("tmp") || filePath.contains("\\tmp\\")
 					|| filePath.contains("/tmp/")) {
 				return false;