diff --git a/lib/cancan/model_adapters/active_record_adapter.rb b/lib/cancan/model_adapters/active_record_adapter.rb
index <HASH>..<HASH> 100644
--- a/lib/cancan/model_adapters/active_record_adapter.rb
+++ b/lib/cancan/model_adapters/active_record_adapter.rb
@@ -73,8 +73,7 @@ module CanCan
                 value.delete(k)
                 nested[k] = v
               else
-                table_name = model_class.reflect_on_association(name).table_name.to_sym
-                result_hash[table_name] = value
+                result_hash[model_class.reflect_on_association(name).table_name.to_sym] = value
               end
               nested
             end
FIX: Variable collision prevents defining permissions with multiple nested conditions