Use unless for force_mobile_view

This commit is contained in:
Clement Ho 2017-07-07 12:17:03 -05:00
parent 8e55acb063
commit 8c92c405d7

View file

@ -91,9 +91,9 @@
method: :post,
class: 'btn btn-success prepend-left-10',
title: 'Grant access' do
%span{ class: ('visible-xs-block' if force_mobile_view == false) }
%span{ class: ('visible-xs-block' unless force_mobile_view) }
Grant access
- if force_mobile_view == false
- unless force_mobile_view
= icon('check inverse', class: 'hidden-xs')
- if can?(current_user, action_member_permission(:destroy, member), member)
@ -109,9 +109,9 @@
data: { confirm: remove_member_message(member) },
class: 'btn btn-remove prepend-left-10',
title: remove_member_title(member) do
%span{ class: ('visible-xs-block' if force_mobile_view == false) }
%span{ class: ('visible-xs-block' unless force_mobile_view) }
Delete
- if force_mobile_view == false
- unless force_mobile_view
= icon('trash', class: 'hidden-xs')
- else
%span.member-access-text= member.human_access