mirror of
https://github.com/nuxt/nuxt.git
synced 2025-01-18 09:25:54 +00:00
refactor(nuxt3): don't include null errors in payload (#2153)
This commit is contained in:
parent
c347b6cc8a
commit
00e6043601
@ -104,7 +104,9 @@ export function useAsyncData<
|
|||||||
.finally(() => {
|
.finally(() => {
|
||||||
asyncData.pending.value = false
|
asyncData.pending.value = false
|
||||||
nuxt.payload.data[key] = asyncData.data.value
|
nuxt.payload.data[key] = asyncData.data.value
|
||||||
nuxt.payload._errors[key] = !!asyncData.error.value
|
if (asyncData.error.value) {
|
||||||
|
nuxt.payload._errors[key] = true
|
||||||
|
}
|
||||||
delete nuxt._asyncDataPromises[key]
|
delete nuxt._asyncDataPromises[key]
|
||||||
})
|
})
|
||||||
return nuxt._asyncDataPromises[key]
|
return nuxt._asyncDataPromises[key]
|
||||||
|
Loading…
Reference in New Issue
Block a user