From: ThibG Date: Mon, 18 Feb 2019 13:59:46 +0000 (+0100) Subject: Add quick link from admin account view to block/unblock instance (#10073) X-Git-Url: https://git.xn--scling-oua.cat.family/?a=commitdiff_plain;h=3a8cb6c73715919a61709bd7ce67fc5ec8d192f9;p=mastodon.git Add quick link from admin account view to block/unblock instance (#10073) --- diff --git a/app/views/admin/accounts/show.html.haml b/app/views/admin/accounts/show.html.haml index 280a834ba..7ac73bd07 100644 --- a/app/views/admin/accounts/show.html.haml +++ b/app/views/admin/accounts/show.html.haml @@ -166,6 +166,12 @@ - else = link_to t('admin.accounts.perform_full_suspension'), new_admin_account_action_path(@account.id, type: 'suspend'), class: 'button button--destructive' if can?(:suspend, @account) + - unless @account.local? + - if DomainBlock.where(domain: @account.domain).exists? + = link_to t('admin.domain_blocks.undo'), admin_instance_path(@account.domain), class: 'button' + - else + = link_to t('admin.domain_blocks.add_new'), new_admin_domain_block_path(_domain: @account.domain), class: 'button button--destructive' + %hr.spacer/ - unless @warnings.empty?