Don't show empty channel button

This commit is contained in:
Arkadiusz Fal 2022-11-18 22:46:00 +01:00
parent a1ade66594
commit 59eda3af26

View File

@ -303,7 +303,8 @@ struct VideoCell: View {
} }
} }
private func channelButton(badge: Bool = true) -> some View { @ViewBuilder private func channelButton(badge: Bool = true) -> some View {
if !video.channel.name.isEmpty {
Button { Button {
guard !inChannelView else { guard !inChannelView else {
return return
@ -333,6 +334,7 @@ struct VideoCell: View {
#endif #endif
.help("\(video.channel.name) Channel") .help("\(video.channel.name) Channel")
} }
}
private var additionalDetailsAvailable: Bool { private var additionalDetailsAvailable: Bool {
video.publishedDate != nil || video.views != 0 || video.publishedDate != nil || video.views != 0 ||