fix staff tag showing for staff hiding a role

This commit is contained in:
byte[] 2020-07-13 13:09:30 -04:00
parent 03897624fe
commit b58bb87d71
2 changed files with 2 additions and 2 deletions

View file

@ -4,7 +4,7 @@ defmodule PhilomenaWeb.SourceChangeView do
def staff?(source_change),
do:
not is_nil(source_change.user) and not Philomena.Attribution.anonymous?(source_change) and
source_change.user.role != "user"
source_change.user.role != "user" and not source_change.user.hide_default_role
def user_column_class(source_change) do
case staff?(source_change) do

View file

@ -4,7 +4,7 @@ defmodule PhilomenaWeb.TagChangeView do
def staff?(tag_change),
do:
not is_nil(tag_change.user) and not Philomena.Attribution.anonymous?(tag_change) and
tag_change.user.role != "user"
tag_change.user.role != "user" and not tag_change.user.hide_default_role
def user_column_class(tag_change) do
case staff?(tag_change) do