mirror of
https://gitea.invidious.io/iv-org/invidious-copy-2022-08-14.git
synced 2024-08-15 00:53:20 +00:00
Handle channels with empty home pages
This commit is contained in:
parent
7662d925e4
commit
efd53285cf
30 changed files with 64 additions and 28 deletions
|
@ -449,5 +449,6 @@
|
||||||
"Licenses": "",
|
"Licenses": "",
|
||||||
"Privacy": "",
|
"Privacy": "",
|
||||||
"short": "",
|
"short": "",
|
||||||
"long": ""
|
"long": "",
|
||||||
|
"This channel doesn't have any content.": ""
|
||||||
}
|
}
|
||||||
|
|
|
@ -449,5 +449,6 @@
|
||||||
"Licenses": "",
|
"Licenses": "",
|
||||||
"Privacy": "",
|
"Privacy": "",
|
||||||
"short": "",
|
"short": "",
|
||||||
"long": ""
|
"long": "",
|
||||||
|
"This channel doesn't have any content.": ""
|
||||||
}
|
}
|
||||||
|
|
|
@ -449,5 +449,6 @@
|
||||||
"Licenses": "",
|
"Licenses": "",
|
||||||
"Privacy": "",
|
"Privacy": "",
|
||||||
"short": "",
|
"short": "",
|
||||||
"long": ""
|
"long": "",
|
||||||
|
"This channel doesn't have any content.": ""
|
||||||
}
|
}
|
||||||
|
|
|
@ -449,5 +449,6 @@
|
||||||
"Licenses": "Licences",
|
"Licenses": "Licences",
|
||||||
"Privacy": "Privacy",
|
"Privacy": "Privacy",
|
||||||
"short": "Short (< 4 minutes)",
|
"short": "Short (< 4 minutes)",
|
||||||
"long": "Long (> 20 minutes)"
|
"long": "Long (> 20 minutes)",
|
||||||
|
"This channel doesn't have any content.": "This channel doesn't have any content."
|
||||||
}
|
}
|
||||||
|
|
|
@ -449,5 +449,6 @@
|
||||||
"Licenses": "",
|
"Licenses": "",
|
||||||
"Privacy": "",
|
"Privacy": "",
|
||||||
"short": "",
|
"short": "",
|
||||||
"long": ""
|
"long": "",
|
||||||
|
"This channel doesn't have any content.": ""
|
||||||
}
|
}
|
||||||
|
|
|
@ -449,5 +449,6 @@
|
||||||
"Licenses": "",
|
"Licenses": "",
|
||||||
"Privacy": "",
|
"Privacy": "",
|
||||||
"short": "",
|
"short": "",
|
||||||
"long": ""
|
"long": "",
|
||||||
|
"This channel doesn't have any content.": ""
|
||||||
}
|
}
|
||||||
|
|
|
@ -449,5 +449,6 @@
|
||||||
"Licenses": "",
|
"Licenses": "",
|
||||||
"Privacy": "",
|
"Privacy": "",
|
||||||
"short": "",
|
"short": "",
|
||||||
"long": ""
|
"long": "",
|
||||||
|
"This channel doesn't have any content.": ""
|
||||||
}
|
}
|
||||||
|
|
|
@ -449,5 +449,6 @@
|
||||||
"Licenses": "",
|
"Licenses": "",
|
||||||
"Privacy": "",
|
"Privacy": "",
|
||||||
"short": "",
|
"short": "",
|
||||||
"long": ""
|
"long": "",
|
||||||
|
"This channel doesn't have any content.": ""
|
||||||
}
|
}
|
||||||
|
|
|
@ -449,5 +449,6 @@
|
||||||
"Licenses": "",
|
"Licenses": "",
|
||||||
"Privacy": "",
|
"Privacy": "",
|
||||||
"short": "",
|
"short": "",
|
||||||
"long": ""
|
"long": "",
|
||||||
|
"This channel doesn't have any content.": ""
|
||||||
}
|
}
|
||||||
|
|
|
@ -449,5 +449,6 @@
|
||||||
"Licenses": "",
|
"Licenses": "",
|
||||||
"Privacy": "",
|
"Privacy": "",
|
||||||
"short": "",
|
"short": "",
|
||||||
"long": ""
|
"long": "",
|
||||||
|
"This channel doesn't have any content.": ""
|
||||||
}
|
}
|
||||||
|
|
|
@ -449,5 +449,6 @@
|
||||||
"Licenses": "",
|
"Licenses": "",
|
||||||
"Privacy": "",
|
"Privacy": "",
|
||||||
"short": "",
|
"short": "",
|
||||||
"long": ""
|
"long": "",
|
||||||
|
"This channel doesn't have any content.": ""
|
||||||
}
|
}
|
||||||
|
|
|
@ -449,5 +449,6 @@
|
||||||
"Licenses": "",
|
"Licenses": "",
|
||||||
"Privacy": "",
|
"Privacy": "",
|
||||||
"short": "",
|
"short": "",
|
||||||
"long": ""
|
"long": "",
|
||||||
|
"This channel doesn't have any content.": ""
|
||||||
}
|
}
|
||||||
|
|
|
@ -449,5 +449,6 @@
|
||||||
"Licenses": "",
|
"Licenses": "",
|
||||||
"Privacy": "",
|
"Privacy": "",
|
||||||
"short": "",
|
"short": "",
|
||||||
"long": ""
|
"long": "",
|
||||||
|
"This channel doesn't have any content.": ""
|
||||||
}
|
}
|
||||||
|
|
|
@ -449,5 +449,6 @@
|
||||||
"Licenses": "",
|
"Licenses": "",
|
||||||
"Privacy": "",
|
"Privacy": "",
|
||||||
"short": "",
|
"short": "",
|
||||||
"long": ""
|
"long": "",
|
||||||
|
"This channel doesn't have any content.": ""
|
||||||
}
|
}
|
||||||
|
|
|
@ -449,5 +449,6 @@
|
||||||
"Licenses": "",
|
"Licenses": "",
|
||||||
"Privacy": "",
|
"Privacy": "",
|
||||||
"short": "",
|
"short": "",
|
||||||
"long": ""
|
"long": "",
|
||||||
|
"This channel doesn't have any content.": ""
|
||||||
}
|
}
|
||||||
|
|
|
@ -449,5 +449,6 @@
|
||||||
"Licenses": "",
|
"Licenses": "",
|
||||||
"Privacy": "",
|
"Privacy": "",
|
||||||
"short": "",
|
"short": "",
|
||||||
"long": ""
|
"long": "",
|
||||||
|
"This channel doesn't have any content.": ""
|
||||||
}
|
}
|
||||||
|
|
|
@ -449,5 +449,6 @@
|
||||||
"Licenses": "",
|
"Licenses": "",
|
||||||
"Privacy": "",
|
"Privacy": "",
|
||||||
"short": "",
|
"short": "",
|
||||||
"long": ""
|
"long": "",
|
||||||
|
"This channel doesn't have any content.": ""
|
||||||
}
|
}
|
||||||
|
|
|
@ -449,5 +449,6 @@
|
||||||
"Licenses": "",
|
"Licenses": "",
|
||||||
"Privacy": "",
|
"Privacy": "",
|
||||||
"short": "",
|
"short": "",
|
||||||
"long": ""
|
"long": "",
|
||||||
|
"This channel doesn't have any content.": ""
|
||||||
}
|
}
|
||||||
|
|
|
@ -449,5 +449,6 @@
|
||||||
"Licenses": "",
|
"Licenses": "",
|
||||||
"Privacy": "",
|
"Privacy": "",
|
||||||
"short": "",
|
"short": "",
|
||||||
"long": ""
|
"long": "",
|
||||||
|
"This channel doesn't have any content.": ""
|
||||||
}
|
}
|
||||||
|
|
|
@ -449,5 +449,6 @@
|
||||||
"Licenses": "",
|
"Licenses": "",
|
||||||
"Privacy": "",
|
"Privacy": "",
|
||||||
"short": "",
|
"short": "",
|
||||||
"long": ""
|
"long": "",
|
||||||
|
"This channel doesn't have any content.": ""
|
||||||
}
|
}
|
||||||
|
|
|
@ -449,5 +449,6 @@
|
||||||
"Licenses": "",
|
"Licenses": "",
|
||||||
"Privacy": "",
|
"Privacy": "",
|
||||||
"short": "",
|
"short": "",
|
||||||
"long": ""
|
"long": "",
|
||||||
|
"This channel doesn't have any content.": ""
|
||||||
}
|
}
|
||||||
|
|
|
@ -449,5 +449,6 @@
|
||||||
"Licenses": "",
|
"Licenses": "",
|
||||||
"Privacy": "",
|
"Privacy": "",
|
||||||
"short": "",
|
"short": "",
|
||||||
"long": ""
|
"long": "",
|
||||||
|
"This channel doesn't have any content.": ""
|
||||||
}
|
}
|
||||||
|
|
|
@ -449,5 +449,6 @@
|
||||||
"Licenses": "",
|
"Licenses": "",
|
||||||
"Privacy": "",
|
"Privacy": "",
|
||||||
"short": "",
|
"short": "",
|
||||||
"long": ""
|
"long": "",
|
||||||
|
"This channel doesn't have any content.": ""
|
||||||
}
|
}
|
||||||
|
|
|
@ -449,5 +449,6 @@
|
||||||
"Licenses": "",
|
"Licenses": "",
|
||||||
"Privacy": "",
|
"Privacy": "",
|
||||||
"short": "",
|
"short": "",
|
||||||
"long": ""
|
"long": "",
|
||||||
|
"This channel doesn't have any content.": ""
|
||||||
}
|
}
|
||||||
|
|
|
@ -449,5 +449,6 @@
|
||||||
"Licenses": "",
|
"Licenses": "",
|
||||||
"Privacy": "",
|
"Privacy": "",
|
||||||
"short": "",
|
"short": "",
|
||||||
"long": ""
|
"long": "",
|
||||||
|
"This channel doesn't have any content.": ""
|
||||||
}
|
}
|
||||||
|
|
|
@ -449,5 +449,6 @@
|
||||||
"Licenses": "",
|
"Licenses": "",
|
||||||
"Privacy": "",
|
"Privacy": "",
|
||||||
"short": "",
|
"short": "",
|
||||||
"long": ""
|
"long": "",
|
||||||
|
"This channel doesn't have any content.": ""
|
||||||
}
|
}
|
||||||
|
|
|
@ -449,5 +449,6 @@
|
||||||
"Licenses": "",
|
"Licenses": "",
|
||||||
"Privacy": "",
|
"Privacy": "",
|
||||||
"short": "",
|
"short": "",
|
||||||
"long": ""
|
"long": "",
|
||||||
|
"This channel doesn't have any content.": ""
|
||||||
}
|
}
|
||||||
|
|
|
@ -311,6 +311,9 @@ private class YoutubeTabsExtractor < ItemsContainerExtractor
|
||||||
elsif items_container = renderer_container_contents["channelVideoPlayerRenderer"]?
|
elsif items_container = renderer_container_contents["channelVideoPlayerRenderer"]?
|
||||||
# Parsing for channel trailer is already taken elsewhere
|
# Parsing for channel trailer is already taken elsewhere
|
||||||
next
|
next
|
||||||
|
elsif items_container = renderer_container_contents["messageRenderer"]?
|
||||||
|
# Likely an error message regarding content being empty
|
||||||
|
next
|
||||||
else
|
else
|
||||||
items_container = renderer_container_contents
|
items_container = renderer_container_contents
|
||||||
end
|
end
|
||||||
|
|
|
@ -16,7 +16,7 @@ class Invidious::Routes::Channels < Invidious::Routes::BaseRoute
|
||||||
items = fetch_channel_home(ucid, channel)
|
items = fetch_channel_home(ucid, channel)
|
||||||
|
|
||||||
has_trailer = false
|
has_trailer = false
|
||||||
if items[0].is_a? Video
|
if !items.empty? && items[0].is_a? Video
|
||||||
has_trailer = true
|
has_trailer = true
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
@ -57,4 +57,10 @@
|
||||||
</div>
|
</div>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
|
<% if items.size == 0 %>
|
||||||
|
<h3 class="pure-u-1 h-box">
|
||||||
|
<%= translate(locale, "This channel doesn't have any content.")%>
|
||||||
|
</h3>
|
||||||
|
<% end %>
|
||||||
</div>
|
</div>
|
Loading…
Reference in a new issue