fix(desktop): use store dir for unified store path (#5799)
The desktop shell was reading from `instance/hoppscotch-unified.store` while the webapp writes to `store/hoppscotch-unified.store`. This caused the app to lose track of the last connected instance on restart. Closes FE-1121
This commit is contained in:
parent
c64928885f
commit
6348d17955
1 changed files with 3 additions and 3 deletions
|
|
@ -33,10 +33,10 @@ export const getInstanceDir = async (): Promise<string> => {
|
||||||
|
|
||||||
const getStorePath = async (): Promise<string> => {
|
const getStorePath = async (): Promise<string> => {
|
||||||
try {
|
try {
|
||||||
const instanceDir = await getInstanceDir()
|
const storeDir = await getStoreDir()
|
||||||
return join(instanceDir, STORE_PATH)
|
return join(storeDir, STORE_PATH)
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.error("Failed to get instance directory:", error)
|
console.error("Failed to get store directory:", error)
|
||||||
return "hoppscotch-unified.store"
|
return "hoppscotch-unified.store"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue