Skip to content

Commit

Permalink
chore: some small code cleanups in PlaylistPage.vue (#3741)
Browse files Browse the repository at this point in the history
  • Loading branch information
Bnyro authored Jul 29, 2024
1 parent 0c4d948 commit c80c0ce
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions src/components/PlaylistPage.vue
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ export default {
this.loading = false;
this.playlist.relatedStreams.push(...json.relatedStreams);
this.updateTotalDuration();
this.fetchDeArrowContent(this.playlist.relatedStreams);
this.fetchDeArrowContent(json.relatedStreams);
});
}
},
Expand All @@ -157,10 +157,11 @@ export default {
});
},
downloadPlaylistAsTxt() {
var data = "";
this.playlist.relatedStreams.forEach(element => {
data += "https://piped.video" + element.url + "\n";
});
const data = this.playlist.relatedStreams
.map(video => {
return "https://piped.video" + video.url;
})
.join("\n");
this.download(data, this.playlist.name + ".txt", "text/plain");
},
async bookmarkPlaylist() {
Expand Down

0 comments on commit c80c0ce

Please sign in to comment.