chore: address linter warnings

Signed-off-by: Toni Förster <toni.foerster@gmail.com>
This commit is contained in:
Toni Förster
2024-08-18 14:46:51 +02:00
parent af75afa912
commit 94577332a1
30 changed files with 164 additions and 103 deletions

View File

@@ -15,7 +15,7 @@ struct FeedView: View {
#endif
var videos: [ContentItem] {
guard let selectedChannel = selectedChannel else {
guard let selectedChannel else {
return ContentItem.array(of: feed.videos)
}
return ContentItem.array(of: feed.videos.filter {
@@ -24,9 +24,7 @@ struct FeedView: View {
}
var channels: [Channel] {
feed.videos.map {
$0.channel
}.unique()
feed.videos.map(\.channel).unique()
}
@State private var selectedChannel: Channel?
@@ -272,7 +270,7 @@ struct FeedView: View {
}
var channelHeaderView: some View {
guard let selectedChannel = selectedChannel else {
guard let selectedChannel else {
return AnyView(
Text("All Channels")
.font(.caption)