Can I order my users in the database, so I don’t have to say order_by(“created_at desc”) each time I query?
Sounds for me like a logical thing to do, but I don’t know if it’s possible and if it’s best practice?
SOLUTION
I’m already using the default_scope and as I understand it from you, it is the best way to do it? Thanks a lot for the answers though.
There are mixed views about default scopes, but to achieve what you’re asking:
http://apidock.com/rails/ActiveRecord/Base/default_scope/class