Skip to content

Commit 12fdb9b

Browse files
authored
AP595: Stack Pass Request admin form showing Forbidden when not logged in (#30)
1 parent 09beec0 commit 12fdb9b

2 files changed

Lines changed: 2 additions & 0 deletions

File tree

app/controllers/reference_card_forms_controller.rb

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,7 @@ def validate_recaptcha!
8484
end
8585

8686
def require_admin!
87+
authenticate!
8788
@user_is_admin = current_user.role?(Role.stackpass_admin)
8889
raise Error::ForbiddenError unless @user_is_admin
8990
end

app/controllers/stack_pass_forms_controller.rb

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,7 @@ def validate_recaptcha!
8686
end
8787

8888
def require_admin!
89+
authenticate!
8990
@user_is_admin = current_user.role?(Role.stackpass_admin)
9091
raise Error::ForbiddenError unless @user_is_admin
9192
end

0 commit comments

Comments
 (0)