Commit fcb94b9
committed
Fix VssStoreIdProvider cache to be per walletIndex
This change ensures that VSS store ID derivation maintains separate
caches for each wallet index, preventing collisions when managing
multiple wallets within the same application instance.
Changes:
- Replace single cachedStoreId with cachedStoreIds map keyed by walletIndex
- Update getVssStoreId() to accept walletIndex parameter (defaults to 0)
- Add clearCache() method to clear all cached store IDs
- Add clearCache(walletIndex) method to clear cache for specific wallet
- Update LightningService to pass walletIndex when getting store ID
- Enhance logging to include walletIndex
This matches the improvements from bitkit-ios PR #202, commit 91b47ba.1 parent 9d6cbd0 commit fcb94b9
File tree
2 files changed
+19
-7
lines changed- app/src/main/java/to/bitkit
- data/backup
- services
2 files changed
+19
-7
lines changedLines changed: 18 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
16 | | - | |
| 16 | + | |
17 | 17 | | |
18 | | - | |
19 | | - | |
| 18 | + | |
| 19 | + | |
20 | 20 | | |
21 | 21 | | |
22 | | - | |
| 22 | + | |
23 | 23 | | |
24 | 24 | | |
25 | 25 | | |
| |||
30 | 30 | | |
31 | 31 | | |
32 | 32 | | |
33 | | - | |
34 | | - | |
| 33 | + | |
| 34 | + | |
35 | 35 | | |
36 | 36 | | |
37 | 37 | | |
38 | 38 | | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
39 | 51 | | |
40 | 52 | | |
41 | 53 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
104 | 104 | | |
105 | 105 | | |
106 | 106 | | |
107 | | - | |
| 107 | + | |
108 | 108 | | |
109 | 109 | | |
110 | 110 | | |
| |||
0 commit comments