don't authorize based on resource name in authorize_resource since this is already handled by enable_authorization

This commit is contained in:
Ryan Bates
2011-03-25 16:40:20 -07:00
parent 27eba72e4b
commit f41b39406c
2 changed files with 8 additions and 7 deletions
+1 -1
View File
@@ -33,7 +33,7 @@ module CanCan
end
def authorize_resource
@controller.authorize!(authorization_action, resource_instance || subject_name_with_parent)
@controller.authorize!(authorization_action, resource_instance) if resource_instance
end
def parent?