3 ms·
Interesting. Do you know (honest question) why they didn't just make find(:all) work that way? In my imagined perfect world they'd have never got rid of find_a
by mapgrep 15y ago
Interesting. Do you know (honest question) why they didn't just make find(:all) work that way? In my imagined perfect world they'd have never got rid of find_all in the first place, and they'd have just added the lazy eval to it later. Or, failing that, done similar with find(:all).
Enjoy your podcast.
- petercooper 15y agoAs I'm not on the Rails core team and didn't really pay much attention to their design process, all I can offer is the major rewrite of ActiveRecord from 2 to 3 and, specifically, the introduction of Arel in AR3 had huge implications for the API design. Specifically, check out the README at https://github.com/rails/arel https://github.com/rails/arel .. if you're familiar with Rails 2 and earlier, the sorts of things you'll see there probably seem quite alien to you. I believe AR had to change a lot to fit in with this approach to SQL generation. (And thanks!)