fix home not loading madeforyou if you have no friends
This commit is contained in:
parent
155ed94551
commit
f930f0fd16
1 changed files with 20 additions and 14 deletions
|
@ -44,7 +44,7 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="row">
|
<div class="row" v-if="friendsListeningTo && friendsListeningTo != []">
|
||||||
<div class="col">
|
<div class="col">
|
||||||
<h3>Friends Listening To</h3>
|
<h3>Friends Listening To</h3>
|
||||||
<div class="well">
|
<div class="well">
|
||||||
|
@ -109,19 +109,25 @@
|
||||||
}
|
}
|
||||||
).then((data) => {
|
).then((data) => {
|
||||||
console.log(data.data[1])
|
console.log(data.data[1])
|
||||||
self.recentlyPlayed = data.data[1].relationships.contents.data
|
try{
|
||||||
self.friendsListeningTo = data.data.filter(section => {
|
self.madeForYou = data.data.filter(section => {
|
||||||
if (section.meta.metrics.moduleType == "11") {
|
if (section.meta.metrics.moduleType == "6") {
|
||||||
return section
|
return section
|
||||||
}
|
}
|
||||||
;
|
;
|
||||||
})[0].relationships.contents.data
|
})[0].relationships.contents.data
|
||||||
self.madeForYou = data.data.filter(section => {
|
}
|
||||||
if (section.meta.metrics.moduleType == "6") {
|
catch(err){}
|
||||||
return section
|
try{
|
||||||
}
|
self.recentlyPlayed = data.data[1].relationships.contents.data
|
||||||
;
|
self.friendsListeningTo = data.data.filter(section => {
|
||||||
})[0].relationships.contents.data
|
if (section.meta.metrics.moduleType == "11") {
|
||||||
|
return section
|
||||||
|
}
|
||||||
|
;
|
||||||
|
})[0].relationships.contents.data
|
||||||
|
}catch(err){}
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
app.mk.api.v3.music("/v1/me/social/profile/").then((response) => {
|
app.mk.api.v3.music("/v1/me/social/profile/").then((response) => {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue