瀏覽代碼

修改请求逻辑

tianboguang 2 年之前
父節點
當前提交
b37c9fd4ae
共有 1 個文件被更改,包括 3 次插入0 次删除
  1. 3 0
      4dkankan-utils-fyun-https/src/main/java/com/fdkankan/fyun/http/HttpFileService.java

+ 3 - 0
4dkankan-utils-fyun-https/src/main/java/com/fdkankan/fyun/http/HttpFileService.java

@@ -307,6 +307,9 @@ public class HttpFileService extends AbstractFYunFileService {
             if (!sourcePath.startsWith(File.separator)) {
                 sourcePath = File.separator.concat(sourcePath);
             }
+            if (sourcePath.endsWith(File.separator)) {
+                sourcePath = sourcePath.substring(0, sourcePath.length() - 1);
+            }
 
             params.put("dirName", sourcePath);
             String url = fYunFileConfig.getEndPoint() + httpFyunConfig.getListDir();