feat: 支持中文路径

This commit is contained in:
cc
2026-01-29 21:59:29 +08:00
parent 26fbfd2c98
commit b3aaea16f2
2 changed files with 11 additions and 12 deletions

View File

@@ -18,8 +18,7 @@ export class DbPathService {
// 微信4.x 数据目录
possiblePaths.push(join(home, 'Documents', 'xwechat_files'))
// 旧版微信数据目录
possiblePaths.push(join(home, 'Documents', 'WeChat Files'))
for (const path of possiblePaths) {
if (existsSync(path)) {
@@ -69,7 +68,7 @@ export class DbPathService {
}
}
}
} catch {}
} catch { }
return accounts
}
@@ -139,7 +138,7 @@ export class DbPathService {
const modifiedTime = this.getAccountModifiedTime(fullPath)
wxids.push({ wxid: account, modifiedTime })
}
} catch {}
} catch { }
return wxids.sort((a, b) => {
if (b.modifiedTime !== a.modifiedTime) return b.modifiedTime - a.modifiedTime

Binary file not shown.