Remove Channel.ParentNameWithFallback

This commit is contained in:
Tyrrrz
2023-09-07 16:36:29 +03:00
parent 59344cedbe
commit 5abe74894c
24 changed files with 112 additions and 110 deletions

View File

@@ -13,10 +13,10 @@ public class ChannelToGroupKeyConverter : IValueConverter
public object? Convert(object value, Type targetType, object parameter, CultureInfo culture) =>
value switch
{
Channel channel when channel.Kind.IsThread()
=> $"Threads in #{channel.ParentNameWithFallback}",
Channel { IsThread: true, Parent: not null } channel
=> $"Threads in #{channel.Parent.Name}",
Channel channel => channel.ParentNameWithFallback,
Channel channel => channel.Parent?.Name ?? "???",
_ => null
};