chore(front): cleanup

2448-complete-tags
Flupsi 2025-06-06 19:32:02 +02:00
rodzic 8cbee81149
commit c68a2073b4
4 zmienionych plików z 7 dodań i 6 usunięć

Wyświetl plik

@ -67,7 +67,7 @@ const performSearch = () => {
}
watch(
[() => store.state.moderation.lastUpdate, page],
() => [store.state.moderation.lastUpdate, page.value],
() => fetchData(),
{ immediate: true }
)

Wyświetl plik

@ -83,7 +83,7 @@ onMounted(() => {
})
watch(
[() => store.state.moderation.lastUpdate, page],
() => [store.state.moderation.lastUpdate, page.value],
() => fetchData(),
{ immediate: true }
)

Wyświetl plik

@ -1,5 +1,5 @@
<script setup lang="ts">
import type { Track, Artist, Library, ArtistCredit } from '~/types'
import type { Track, Library } from '~/types'
import { momentFormat } from '~/utils/filters'
import { computed, reactive, ref, watch } from 'vue'
@ -43,7 +43,7 @@ const props = defineProps<Props>()
const object = computed(() => dataStore.get("album", props.id).value)
const artistCredit = computed(() => object.value?.artist_credit ?? [])
const artist = computed(() => dataStore.get("artist", artistCredit.value[0].artist.id))
const libraries = ref([] as Library[])
const paginateBy = ref(50)
@ -131,7 +131,8 @@ const remove = async () => {
try {
await axios.delete(`albums/${object.value?.id}`)
emit('deleted')
router.push({ name: 'library.artists.detail', params: { id: artist.value?.id } })
if (artistCredit.value)
router.push({ name: 'library.artists.detail', params: { id: artistCredit.value[0].artist.id } })
} catch (error) {
useErrorHandler(error as Error)
}

Wyświetl plik

@ -60,7 +60,7 @@ const fetchData = async (url = props.url) => {
fetchData()
watch(
[() => store.state.moderation.lastUpdate, page],
() => [store.state.moderation.lastUpdate, page.value],
() => fetchData(),
{ immediate: true }
)