@hienlh/ppm 0.7.12 → 0.7.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +5 -0
- package/package.json +1 -1
- package/src/services/account.service.ts +7 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,10 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [0.7.13] - 2026-03-20
|
|
4
|
+
|
|
5
|
+
### Fixed
|
|
6
|
+
- **Account decrypt crash on different machine**: `getWithTokens` now catches decrypt errors (mismatched `account.key`) and returns `null` instead of crashing the API
|
|
7
|
+
|
|
3
8
|
## [0.7.12] - 2026-03-20
|
|
4
9
|
|
|
5
10
|
### Fixed
|
package/package.json
CHANGED
|
@@ -66,7 +66,13 @@ class AccountService {
|
|
|
66
66
|
|
|
67
67
|
getWithTokens(id: string): AccountWithTokens | null {
|
|
68
68
|
const row = getAccountById(id);
|
|
69
|
-
|
|
69
|
+
if (!row) return null;
|
|
70
|
+
try {
|
|
71
|
+
return this.toAccountWithTokens(row);
|
|
72
|
+
} catch (e) {
|
|
73
|
+
console.error(`[accounts] Failed to decrypt tokens for ${row.label ?? id}:`, (e as Error).message);
|
|
74
|
+
return null;
|
|
75
|
+
}
|
|
70
76
|
}
|
|
71
77
|
|
|
72
78
|
add(params: {
|