Skip to content

Commit

Permalink
Dialog: fix a NaN error!
Browse files Browse the repository at this point in the history
  • Loading branch information
curiousdannii committed Oct 18, 2024
1 parent 29c8c84 commit 60c5489
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/dialog/browser/storage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@ const DIALOG_V1_TYPES_TO_EXTS: Record<string, string> = {
}
export function migrate_localStorage() {
const now = Date.now()
const version = parseInt(localStorage.getItem(STORAGE_VERSION_KEY) || '', 10)
const version = parseInt(localStorage.getItem(STORAGE_VERSION_KEY) || '', 10) || 0
if (version < 2) {
console.log('Dialog: updating localStorage to version 2')
const metadata: FilesMetadata = {}
Expand Down

0 comments on commit 60c5489

Please sign in to comment.