Update model.rb

updated the conditions of the has_many to the new arel-syntax to get rid of nasty warnings.