fix: logic error prevent status action menu display intro in 80ea6ac

This commit is contained in:
CMK 2021-10-11 11:07:42 +08:00
parent 3b7e52edfa
commit 051a8f40e3
1 changed files with 0 additions and 9 deletions

View File

@ -221,8 +221,6 @@ extension UserProviderFacade {
state: .off
) { [weak provider, weak sourceView, weak barButtonItem] _ in
guard let provider = provider else { return }
guard let sourceView = sourceView else { return }
guard let barButtonItem = barButtonItem else { return }
let activityViewController = createActivityViewControllerForMastodonUser(mastodonUser: shareUser, dependency: provider)
provider.coordinator.present(
scene: .activityViewController(
@ -247,8 +245,6 @@ extension UserProviderFacade {
state: .off
) { [weak provider, weak sourceView, weak barButtonItem] _ in
guard let provider = provider else { return }
guard let sourceView = sourceView else { return }
guard let barButtonItem = barButtonItem else { return }
let activityViewController = createActivityViewControllerForMastodonUser(status: shareStatus, dependency: provider)
provider.coordinator.present(
scene: .activityViewController(
@ -273,7 +269,6 @@ extension UserProviderFacade {
state: .off
) { [weak provider, weak cell] _ in
guard let provider = provider else { return }
guard let cell = cell else { return }
UserProviderFacade.toggleUserMuteRelationship(
provider: provider,
@ -304,7 +299,6 @@ extension UserProviderFacade {
state: .off
) { [weak provider, weak cell] _ in
guard let provider = provider else { return }
guard let cell = cell else { return }
UserProviderFacade.toggleUserBlockRelationship(
provider: provider,
@ -364,7 +358,6 @@ extension UserProviderFacade {
state: .off
) { [weak provider, weak cell] _ in
guard let provider = provider else { return }
guard let cell = cell else { return }
provider.context.blockDomainService.unblockDomain(userProvider: provider, cell: cell)
}
children.append(unblockDomainAction)
@ -378,14 +371,12 @@ extension UserProviderFacade {
state: .off
) { [weak provider, weak cell] _ in
guard let provider = provider else { return }
guard let cell = cell else { return }
let alertController = UIAlertController(title: L10n.Common.Alerts.BlockDomain.title(mastodonUser.domainFromAcct), message: nil, preferredStyle: .alert)
let cancelAction = UIAlertAction(title: L10n.Common.Controls.Actions.cancel, style: .default) { _ in }
alertController.addAction(cancelAction)
let blockDomainAction = UIAlertAction(title: L10n.Common.Alerts.BlockDomain.blockEntireDomain, style: .destructive) { [weak provider, weak cell] _ in
guard let provider = provider else { return }
guard let cell = cell else { return }
provider.context.blockDomainService.blockDomain(userProvider: provider, cell: cell)
}
alertController.addAction(blockDomainAction)