Always return a boolean value from `moderation_view?`
This commit is contained in:
parent
f5f7b0d22b
commit
b00a12b322
|
@ -18,7 +18,7 @@ module UserHelper
|
||||||
end
|
end
|
||||||
|
|
||||||
def moderation_view?
|
def moderation_view?
|
||||||
current_user&.mod? && session[:moderation_view] == true
|
!!(current_user&.mod? && session[:moderation_view] == true)
|
||||||
end
|
end
|
||||||
|
|
||||||
private
|
private
|
||||||
|
|
Loading…
Reference in New Issue