mirror of
https://github.com/RSS-Bridge/rss-bridge.git
synced 2025-08-29 06:19:07 +02:00
add feedName fallbacks (thanks @Mar-Koeh)
This commit is contained in:
parent
f0202ea893
commit
99c0fe03e0
1 changed files with 5 additions and 1 deletions
|
@ -72,7 +72,11 @@ class YouTubePostsTabBridge extends BridgeAbstract
|
|||
|
||||
$json = $this->extractJson($html->find('html', 0)->innertext);
|
||||
|
||||
$this->feedName = $json->header->c4TabbedHeaderRenderer->title;
|
||||
$this->feedName = $json->header->c4TabbedHeaderRenderer->title
|
||||
?? $json->header->pageHeaderRenderer->pageTitle
|
||||
?? $json->metadata->channelMetadataRenderer->title
|
||||
?? $json->microformat->microformatDataRenderer->title
|
||||
?? '';
|
||||
|
||||
if ($this->hasPostsTab($json) === false) {
|
||||
returnServerError('Channel does not have a posts tab');
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue