Various improvements

This commit is contained in:
Ilya Laktyushin
2022-04-30 03:52:31 +04:00
parent d36b6b0b7f
commit 70ae305e99
41 changed files with 521 additions and 415 deletions

View File

@@ -154,6 +154,15 @@ public extension Peer {
}
}
var isPremium: Bool {
switch self {
case let user as TelegramUser:
return user.flags.contains(.isPremium)
default:
return false
}
}
var isCopyProtectionEnabled: Bool {
switch self {
case let group as TelegramGroup: