Fix Local Backup Loading Failure Due to Incorrect Backup Data Saving.
This commit is contained in:
@@ -115,7 +115,7 @@ export async function LoadLocalBackup(){
|
|||||||
const dbData = await decodeRisuSave(db)
|
const dbData = await decodeRisuSave(db)
|
||||||
DataBase.set(dbData)
|
DataBase.set(dbData)
|
||||||
if(isTauri){
|
if(isTauri){
|
||||||
await writeBinaryFile('database/database.bin', dbData, {dir: BaseDirectory.AppData})
|
await writeBinaryFile('database/database.bin', db, {dir: BaseDirectory.AppData})
|
||||||
relaunch()
|
relaunch()
|
||||||
alertStore.set({
|
alertStore.set({
|
||||||
type: "wait",
|
type: "wait",
|
||||||
@@ -123,7 +123,7 @@ export async function LoadLocalBackup(){
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
else{
|
else{
|
||||||
await forageStorage.setItem('database/database.bin', dbData)
|
await forageStorage.setItem('database/database.bin', db)
|
||||||
location.search = ''
|
location.search = ''
|
||||||
alertStore.set({
|
alertStore.set({
|
||||||
type: "wait",
|
type: "wait",
|
||||||
|
|||||||
Reference in New Issue
Block a user