Fix retain cycle in ProfileViewController

This commit is contained in:
Shadowfacts 2021-08-14 10:25:32 -04:00
parent 7edf0fdb93
commit 09ec4a920c
Signed by untrusted user: shadowfacts
GPG Key ID: 94A5AB95422746E5
1 changed files with 2 additions and 2 deletions

View File

@ -70,8 +70,8 @@ class ProfileViewController: UIPageViewController {
let composeButton = UIBarButtonItem(barButtonSystemItem: .compose, target: self, action: #selector(composeMentioning)) let composeButton = UIBarButtonItem(barButtonSystemItem: .compose, target: self, action: #selector(composeMentioning))
composeButton.menu = UIMenu(title: "", image: nil, identifier: nil, options: [], children: [ composeButton.menu = UIMenu(title: "", image: nil, identifier: nil, options: [], children: [
UIAction(title: "Direct Message", image: UIImage(systemName: Status.Visibility.direct.unfilledImageName), identifier: nil, discoverabilityTitle: nil, attributes: [], state: .off, handler: { (_) in UIAction(title: "Direct Message", image: UIImage(systemName: Status.Visibility.direct.unfilledImageName), identifier: nil, discoverabilityTitle: nil, attributes: [], state: .off, handler: { [weak self] (_) in
self.composeDirectMentioning() self?.composeDirectMentioning()
}) })
]) ])
composeButton.isEnabled = mastodonController.loggedIn composeButton.isEnabled = mastodonController.loggedIn