mirror of
https://github.com/projekteuler/projekteuler.git
synced 2025-12-10 16:46:42 +01:00
8 lines
176 B
Ruby
8 lines
176 B
Ruby
class AdminController < ApplicationController
|
|
before_action :authenticate!
|
|
|
|
def authenticate!
|
|
authenticate_user!
|
|
throw(:warden) unless current_user.admin?
|
|
end
|
|
end |