Using the new eager load API from Rails 4

Closes #478