修复前端错误
This commit is contained in:
@@ -33,7 +33,7 @@ export const usePlayerStore = defineStore('player', () => {
|
|||||||
const song = ref(null)
|
const song = ref(null)
|
||||||
const playlist = ref([])
|
const playlist = ref([])
|
||||||
|
|
||||||
const cover = computed(() => `/api/songs/${song.value.id}/cover`)
|
const cover = computed(() => `/api/songs/${song.value?.id || 0}/cover`)
|
||||||
const progress = computed(() => {
|
const progress = computed(() => {
|
||||||
if (duration.value === 0) return 0
|
if (duration.value === 0) return 0
|
||||||
return (currentTime.value / duration.value) * 100
|
return (currentTime.value / duration.value) * 100
|
||||||
|
|||||||
Reference in New Issue
Block a user