Rails 4.1 compatibility

Rails 4.1 removes the `HasAndBelongsToMany` preloader, to the changes in c91640a don't work anymore. @osheroff would you take a look at it, please?

cc @grosser @pschambacher 
I guess this method is only called once during definition of the association? If so then it is fine. Otherwize we should probably include a module instead of defining this method over and over again.