views:

43

answers:

1

Hi all. Imagine a simple model.

class Service
  belongs_to :user
  validates_associated :user
  accepts_nested_attributes_for :user
end

Nothing special right? The validations on the associated User model trigger correctly in development mode. But don't do anything in production. I've added a validates_on_presence :user just like the docs say. This triggers when there's no User associated with the Service, but fill in one thing on the User model and nothing happens! It's driving me up the walls. Am I overlooking something?

More info about the MVC: I use formtastic for the forms.

Thanks!

A: 

It might be something simple like

  1. Did you restart your server after deploying?
  2. Do you need to run any migrations on the production db?
jspooner