fix(IzTool): 修复 parseFileList 中 get("uuid") 可能导致的 NPE

当 otherParam 中缺少 "uuid" 键时,原代码直接调用 .toString() 会抛出
NullPointerException。改为先取出 Object 再做 null 检查。
This commit is contained in:
yukaidi
2026-05-29 06:36:43 +08:00
parent 741d7aa8ca
commit 0cd77ee9b9

View File

@@ -465,7 +465,10 @@ public class IzTool extends PanBase {
// 如果参数里的目录ID不为空则直接解析目录
String dirId = (String) shareLinkInfo.getOtherParam().get("dirId");
if (dirId != null && !dirId.isEmpty()) {
uuid = shareLinkInfo.getOtherParam().get("uuid").toString();
Object uuidObj = shareLinkInfo.getOtherParam().get("uuid");
if (uuidObj != null) {
uuid = uuidObj.toString();
}
parserDir(dirId, shareId, promise);
return promise.future();
}