Let super admins toggle admin bar

This commit is contained in:
Josh Pigford
2024-11-22 14:22:52 -06:00
parent c309c8abf8
commit c8302a6d49
2 changed files with 9 additions and 1 deletions

View File

@@ -158,4 +158,12 @@ module ApplicationHelper
.map { |_currency, money| format_money(money) }
.join(separator)
end
def show_super_admin_bar?
if params[:admin].present?
cookies.permanent[:admin] = params[:admin]
end
cookies[:admin] == "true"
end
end