Adds account type check for Twitter deprecation alert

This commit is contained in:
Stuart Breckenridge 2023-02-05 21:30:44 +08:00
parent da91548875
commit b83345a47f
No known key found for this signature in database
GPG Key ID: 64DCE361D27B805B
1 changed files with 12 additions and 10 deletions

View File

@ -965,6 +965,7 @@ internal extension AppDelegate {
var twitterIsActive: Bool = false
AccountManager.shared.accounts.forEach({ account in
if account.type == .cloudKit || account.type == .onMyMac {
account.flattenedWebFeeds().forEach({ webfeed in
guard let components = URLComponents(string: webfeed.url),
let host = components.host else {
@ -975,6 +976,7 @@ internal extension AppDelegate {
return
}
})
}
})
if twitterIsActive {
showTwitterDeprecationAlert()