Fix `moderation_view?` breaking when not logged in
This commit is contained in:
parent
6d03eb78d9
commit
93c62a3008
|
@ -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