3 ms·
I hate rails. But one thing I like is that activerecord will build functions for you. e.g.: User.find_by_email(email) I've started writing these types of fu
by endlessvoid94 16y ago
I hate rails. But one thing I like is that activerecord will build functions for you. e.g.:
User.find_by_email(email)
I've started writing these types of functions manually now and it makes EVERYTHING so much simpler.
I never thought I'd say it...but...thank you rails.
- endlessvoid94 16y agoI guess I'm being downvoted for contributing to the discussion?
- chrismsnz 16y agoSo you're using ORM specific functionality in the controller? :)
- endlessvoid94 16y agoI...guess so. But it successfully removes the reason that becomes painful and leaky, e.g., queries. The function names are short and readable, and the execution of the query is in the ORM where it belongs.