| @@ -100,12 +100,8 @@ | ||
| 100 | 100 | |
| 101 | 101 | // Get playlist id from the channel |
| 102 | 102 | $playlist_id = $this->get_playlist_id( $params ); |
| 103 | 103 | |
| 104 | - if ( is_object( $playlist_id ) && isset( $playlist_id->error ) ) { | |
| 105 | - return $playlist_id; | |
| 106 | - } | |
| 107 | - | |
| 108 | 104 | if ( empty( $playlist_id ) ) { |
| 109 | 105 | return $this->get_error( __( 'No videos found matching your query.', 'automatic-youtube-gallery' ) ); |
| 110 | 106 | } |
| 111 | 107 | |
| @@ -121,12 +117,8 @@ | ||
| 121 | 117 | |
| 122 | 118 | // Get playlist id from the channel |
| 123 | 119 | $params['forUsername'] = $this->parse_youtube_id_from_url( $params['src'], 'username' ); |
| 124 | 120 | $playlist_id = $this->get_playlist_id( $params ); |
| 125 | - | |
| 126 | - if ( is_object( $playlist_id ) && isset( $playlist_id->error ) ) { | |
| 127 | - return $playlist_id; | |
| 128 | - } | |
| 129 | 121 | |
| 130 | 122 | if ( empty( $playlist_id ) ) { |
| 131 | 123 | return $this->get_error( __( 'No videos found matching your query.', 'automatic-youtube-gallery' ) ); |
| 132 | 124 | } |