修复特殊符号 转义错误

修复特殊符号 转义错误

Signed-off-by: 高雄 <admin@cxcp.com>
This commit is contained in:
高雄
2023-12-19 06:38:27 +00:00
committed by Gitee
parent a5d29a4e3c
commit 8d56923efc

View File

@@ -205,7 +205,7 @@ public class FileHandlerService implements InitializingBean {
String pdfFolder = pdfFilePath.substring(0, pdfFilePath.length() - 4);
String urlPrefix;
try {
urlPrefix = baseUrl + URLEncoder.encode(pdfFolder, uriEncoding).replaceAll("\\+", "%2B");
urlPrefix = baseUrl + URLEncoder.encode(pdfFolder, uriEncoding).replaceAll("\\+", "%20");
} catch (UnsupportedEncodingException e) {
logger.error("UnsupportedEncodingException", e);
urlPrefix = baseUrl + pdfFolder;