Log messages on session loading
This commit is contained in:
parent
07848907f3
commit
9b58b887b4
|
@ -12,10 +12,12 @@ let wsWatch = null as WebSocket | null
|
||||||
export const loadSession = () => {
|
export const loadSession = () => {
|
||||||
const store = useDocumentStore()
|
const store = useDocumentStore()
|
||||||
try {
|
try {
|
||||||
tree = JSON.parse(sessionStorage["cista-files"])
|
tree = JSON.parse(sessionStorage['cista-files'])
|
||||||
store.updateRoot(tree)
|
store.updateRoot(tree)
|
||||||
|
console.log(`Loaded session ${tree.length} items`)
|
||||||
return true
|
return true
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
|
if (sessionStorage['cista-files']) console.log("Loading session failed", error)
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user