Fix composable issue

This commit is contained in:
Julien Nahum
2024-01-11 17:16:50 +01:00
parent 5a3978874a
commit aa0b9ae02c
6 changed files with 117 additions and 196 deletions

View File

@@ -9,8 +9,8 @@ export const useNotionPagesStore = defineStore('notion_pages', () => {
contentStore.startLoading()
const apiUrl = opnformConfig.notion.worker
return useOpnApi(`${apiUrl}/page/${pageId}`)
.then(({data})=> {
return useFetch(`${apiUrl}/page/${pageId}`)
.then(({data, error})=> {
const val = data.value
val['id'] = pageId
contentStore.save(val)