diff options
author | Jesús <heckyel@hyperbola.info> | 2021-07-09 15:27:16 -0500 |
---|---|---|
committer | Jesús <heckyel@hyperbola.info> | 2021-07-09 15:27:16 -0500 |
commit | 739c821a54c01816e60eb5f774c8977a1e221ea0 (patch) | |
tree | e04a7f5a6fe4d450d43fd45c412f9d415bcb7a7e /lib/WWW/FairViewer/Playlists.pm | |
parent | c1322a4e9a1fb0a286dab1277a740072d0ab30f9 (diff) | |
download | fair-viewer-739c821a54c01816e60eb5f774c8977a1e221ea0.tar.lz fair-viewer-739c821a54c01816e60eb5f774c8977a1e221ea0.tar.xz fair-viewer-739c821a54c01816e60eb5f774c8977a1e221ea0.zip |
upstream
Diffstat (limited to 'lib/WWW/FairViewer/Playlists.pm')
-rw-r--r-- | lib/WWW/FairViewer/Playlists.pm | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/lib/WWW/FairViewer/Playlists.pm b/lib/WWW/FairViewer/Playlists.pm index 01277c0..4294352 100644 --- a/lib/WWW/FairViewer/Playlists.pm +++ b/lib/WWW/FairViewer/Playlists.pm @@ -6,7 +6,7 @@ use warnings; =head1 NAME -WWW::FairViewer::Playlists - Fair playlists handle. +WWW::FairViewer::Playlists - YouTube playlists related mehods. =head1 SYNOPSIS @@ -25,7 +25,7 @@ sub _make_playlists_url { $opts{'part'} = 'snippet,contentDetails'; } - $self->_make_feed_url('playlists', %opts); + $self->_make_feed_url('playlists', %opts,); } sub get_playlist_id { @@ -60,7 +60,13 @@ Get and return playlists from a channel ID. sub playlists { my ($self, $channel_id) = @_; - $self->_get_results($self->_make_feed_url("channels/playlists/$channel_id")); + + if (my $results = $self->yt_channel_playlists($channel_id)) { + return $results; + } + + my $url = $self->_make_feed_url("channels/playlists/$channel_id"); + $self->_get_results($url); } =head2 playlists_from_username($username) |