Skip to content
Snippets Groups Projects
Commit b17ab1eb authored by Eliot Berriot's avatar Eliot Berriot
Browse files

Merge branch '457-artist-no-tracks' into 'develop'

Resolve "Artist showing up while not existing"

Closes #457

See merge request funkwhale/funkwhale!360
parents 75852e53 c53f03c4
No related branches found
No related tags found
No related merge requests found
Fixed crash on artist pages when no cover is available (#457)
<template>
<div>
<div v-if="isLoading" class="ui vertical segment" v-title="labels.title">
<div v-title="labels.title">
<div v-if="isLoading" class="ui vertical segment">
<div :class="['ui', 'centered', 'active', 'inline', 'loader']"></div>
</div>
<template v-if="artist">
......@@ -102,7 +102,7 @@ export default {
self.artist = response.data
self.isLoading = false
self.isLoadingAlbums = true
axios.get('albums/', {params: {artist: this.id, ordering: '-release_date'}}).then((response) => {
axios.get('albums/', {params: {artist: self.id, ordering: '-release_date'}}).then((response) => {
let parsed = JSON.parse(JSON.stringify(response.data.results))
self.albums = parsed.map((album) => {
return backend.Album.clean(album)
......@@ -158,7 +158,7 @@ export default {
})[0]
},
headerStyle () {
if (!this.cover.original) {
if (!this.cover || !this.cover.original) {
return ''
}
return 'background-image: url(' + this.$store.getters['instance/absoluteUrl'](this.cover.original) + ')'
......
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