提交 918dd6e9 编写于 作者: J Javen205

优化接口

上级 fd0fddce
......@@ -20,6 +20,7 @@ import javax.crypto.NoSuchPaddingException;
import java.io.*;
import java.net.URLEncoder;
import java.nio.charset.StandardCharsets;
import java.nio.file.Files;
import java.security.InvalidKeyException;
import java.security.NoSuchAlgorithmException;
import java.security.PrivateKey;
......@@ -531,7 +532,7 @@ public class PayKit {
// 绝对地址
File file = new File(path);
if (file.exists()) {
return new FileInputStream(file);
return Files.newInputStream(file.toPath());
}
// 相对地址
return getFileToStream(path);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册