Skip to content
Snippets Groups Projects
Commit cef55c95 authored by Ryan Bates's avatar Ryan Bates
Browse files

fetch cancan_resource_class through controller class from ControllerResource

parent 7e0e7227
No related branches found
No related tags found
No related merge requests found
......@@ -6,7 +6,7 @@ module CanCan
options = args.extract_options!
resource_name = args.first
controller_class.before_filter(options.slice(:only, :except)) do |controller|
self.class.cancan_resource_class.new(controller, resource_name, options.except(:only, :except)).send(method)
controller.class.cancan_resource_class.new(controller, resource_name, options.except(:only, :except)).send(method)
end
end
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment