1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00
rails--rails/activerecord/lib
Sean Griffin 5e0b555b45 current_scope shouldn't pollute sibling STI classes
It looks like the only reason `current_scope` was thread local on
`base_class` instead of `self` is to ensure that when we call a named
scope created with a proc on the parent class, it correctly uses the
default scope of the subclass. The reason this wasn't happening was
because the proc captured `self` as the parent class, and we're not
actually defining a real method. Using `instance_exec` fixes the
problem.

Fixes #18806
2015-02-11 13:46:30 -07:00
..
active_record current_scope shouldn't pollute sibling STI classes 2015-02-11 13:46:30 -07:00
rails/generators Add Secure Token Generator 2015-01-11 14:42:54 -05:00
active_record.rb Add has_secure_token to Active Record 2015-01-04 11:31:37 -05:00