Devise with many models and ArgumentError in RegistrationController#create

Hello! I write custom registration for different user types.

I have Devise model User and two models (roles) Company and Invidual:
I created UserObserver
Registration view: and partial (by
for Company)

In addition to the fields of User on the form displays the Name field of
Company model.
But when I press the submit button, I get an error “ArgumentError in

Cannot build association character. Are you trying to build a
one-to-one association?

Application Trace | Framework Trace | Full Trace
app/controllers/registration_controller.rb:14:in `create’

How fix it? Thanks for your answers!

If there has_one :character in your model?

Yes, see my models

среда, 8 августа 2012 г., 11:10:48 UTC+4 пользователь zerogy написал:

Maybe this can help you: