From e8e1d862a88b26dafdae27325ca72bcb892f11ec Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Benavente?= Date: Sat, 9 Mar 2024 17:53:46 -0300 Subject: [PATCH] Always authenticate admin users when authenticating for other roles Progress towards #61 --- app/controllers/application_controller.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/controllers/application_controller.rb b/app/controllers/application_controller.rb index b98d6dd6..72de1284 100644 --- a/app/controllers/application_controller.rb +++ b/app/controllers/application_controller.rb @@ -88,11 +88,11 @@ def authenticate_admin end def authenticate_mod - redirect_to root_path, :notice => t('alerts.no-permission') unless user_is_mod? + redirect_to root_path, :notice => t('alerts.no-permission') unless user_is_mod? || user_is_admin? end def authenticate_organizer - redirect_to root_path, :notice => t('alerts.no-permission') unless user_is_organizer? + redirect_to root_path, :notice => t('alerts.no-permission') unless user_is_organizer? || user_is_admin? end def authenticate_staff