Skip to content
Snippets Groups Projects
Commit 082ef2c7 authored by Konrad Mohrfeldt's avatar Konrad Mohrfeldt :koala:
Browse files

fix: properly resolve error from response

refs #257
parent 54017b82
No related branches found
No related tags found
No related merge requests found
...@@ -15,9 +15,9 @@ ...@@ -15,9 +15,9 @@
</template> </template>
<script setup lang="ts"> <script setup lang="ts">
import { computed, ref, watchEffect } from 'vue' import { ref, watchEffect } from 'vue'
import { useRoute, useRouter } from 'vue-router' import { useRoute, useRouter } from 'vue-router'
import { flattenErrorData, useObjectFromStore } from '@rokoli/bnb/drf' import { useErrorList, useObjectFromStore } from '@rokoli/bnb/drf'
import { useI18n } from '@/i18n' import { useI18n } from '@/i18n'
import { useNoteStore, usePlaylistStore, useTimeSlotStore } from '@/stores' import { useNoteStore, usePlaylistStore, useTimeSlotStore } from '@/stores'
...@@ -48,7 +48,7 @@ const { obj: playlist } = useObjectFromStore( ...@@ -48,7 +48,7 @@ const { obj: playlist } = useObjectFromStore(
playlistStore, playlistStore,
) )
const loadingError = ref<Error | undefined>() const loadingError = ref<Error | undefined>()
const loadingErrorList = computed(() => Array.from(flattenErrorData(loadingError.value, 'server.'))) const loadingErrorList = useErrorList(loadingError)
defineNavigationContext(() => ({ episode: timeslot })) defineNavigationContext(() => ({ episode: timeslot }))
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment