修复PathUtil.moveContent当target不存在时会报错问题

This commit is contained in:
Looly 2023-08-02 17:43:32 +08:00
parent 338f2d2aa0
commit 0621543ae3
2 changed files with 4 additions and 0 deletions

View File

@ -10,6 +10,7 @@
### 🐞Bug修复
* 【core 】 修复NumberUtil.toBigDecimal转换科学计数法问题issue#3241@Github
* 【core 】 修复PathUtil.moveContent当target不存在时会报错问题issue#3238@Github
-------------------------------------------------------------------------------------------------------------
# 5.8.21(2023-07-29)

View File

@ -148,6 +148,9 @@ public class PathMover {
final CopyOption[] options = this.options;
// 自动创建目标的父目录
PathUtil.mkParentDirs(target);
// 移动失败可能是跨分区移动导致的采用递归移动方式
walkMove(src, target, options);
return target;