Skip to content

Commit

Permalink
monkey fix again
Browse files Browse the repository at this point in the history
  • Loading branch information
so1ve committed Sep 16, 2023
1 parent 4248f7d commit 96329ee
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions composables/state.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,14 @@ export const options = computed(() => {
? new Function(rawOptions.value)()
: json5.parse(rawOptions.value)
} catch {
console.error(
`Failed to parse options: ${JSON.stringify(rawOptions.value, null, 2)}`
)
return null
try {
return new Function(rawOptions.value)()
} catch {
console.error(
`Failed to parse options: ${JSON.stringify(rawOptions.value, null, 2)}`
)
return null
}
}
})

Expand Down

0 comments on commit 96329ee

Please sign in to comment.