8 lines
199 B
Ruby
8 lines
199 B
Ruby
class ApplicationController < ActionController::Base
|
|
protect_from_forgery
|
|
|
|
rescue_from CanCan::AccessDenied do |exception|
|
|
flash[:error] = "Access denied."
|
|
redirect_to root_url
|
|
end
|
|
end
|