On Fri, Apr 9, 2010 at 12:19 AM, Ho-Sheng Hsiao wrote:
>
>> ...
>
> That sounds like a code smell. :-) See below.
>
>> ...
>
> How about creating the first Model, then the User model, and then
> after that is setup, do the login?

Yeah, I will try that. Think my setup was backwards.

My model is like this:

SearchSubscrtipion belongs_to User
User has_many SearchSubscriptions

In the SearchSubscription model I had a before_create callback that
was trying to create the new user record if not yet available. (Thus
creating it's own parent on the fly.) Seems as if that's impossible.

I will try as you stated, without the before_create callback.

Thanks!

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en.

Reply via email to