Permalink
Browse files

allow :through option to work with private controller methods - closes

  • Loading branch information...
1 parent cb9777b commit dde88c92b72b2e95dd96f11e0bdea8f86bb7c985 @ryanb committed May 17, 2011
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/cancan/controller_resource.rb
@@ -178,7 +178,7 @@ def parent_resource
def fetch_parent(name)
if @controller.instance_variable_defined? "@#{name}"
@controller.instance_variable_get("@#{name}")
- elsif @controller.respond_to? name
+ elsif @controller.respond_to?(name, true)
@controller.send(name)
end
end

0 comments on commit dde88c9

Please sign in to comment.