add missing return in methods
This commit is contained in:
@@ -29,12 +29,11 @@
|
||||
},
|
||||
methods: {
|
||||
toggleStarred() {
|
||||
if (this.starred) {
|
||||
this.$api.unstar('track', this.track.id)
|
||||
} else {
|
||||
this.$api.star('track', this.track.id)
|
||||
}
|
||||
this.starred = !this.starred
|
||||
if (this.starred) {
|
||||
return this.$api.unstar('track', this.track.id)
|
||||
}
|
||||
return this.$api.star('track', this.track.id)
|
||||
},
|
||||
setNextInQueue() {
|
||||
return this.$store.dispatch('player/setNextInQueue', this.track)
|
||||
|
||||
@@ -54,7 +54,7 @@
|
||||
methods: {
|
||||
loadMore() {
|
||||
this.loading = true
|
||||
this.$api.getAlbums(this.sort as AlbumSort, 50, this.offset).then(albums => {
|
||||
return this.$api.getAlbums(this.sort as AlbumSort, 50, this.offset).then(albums => {
|
||||
this.albums.push(...albums)
|
||||
this.offset += albums.length
|
||||
this.hasMore = albums.length > 0
|
||||
|
||||
Reference in New Issue
Block a user