user profile: inactive users don't need further qualifiers

This commit is contained in:
joshua stein 2016-06-22 15:30:06 -05:00
parent 13529cf296
commit 68a9a871ea

View file

@ -27,20 +27,20 @@
<span class="d"
<%= @showing_user.is_banned? ? raw("style=\"color: red;\"") : "" %>>
<% if @showing_user.is_banned? %>
Banned
Banned user
<% elsif !@showing_user.is_active? %>
Inactive
Inactive user
<% else %>
Active
<% end %>
<%= @showing_user.is_admin? ? "administrator" :
(@showing_user.is_moderator? ? "moderator" : "user") %>
<% if !@showing_user.can_invite? %>
with invites
<% if !@showing_user.can_submit_stories? %>
and story submissions
<%= @showing_user.is_admin? ? "administrator" :
(@showing_user.is_moderator? ? "moderator" : "user") %>
<% if !@showing_user.can_invite? %>
with invites
<% if !@showing_user.can_submit_stories? %>
and story submissions
<% end %>
disabled
<% end %>
disabled
<% end %>
</span>
<br>