I'm getting an error I can't figure out.

I have a "UserProfile" class that is the AUTH_PROFILE_MODULE setting,
but then when I am trying to create an object from a model class that
has a ForeignKey for that UserProfile class

char = Character(
    user_profile = request.user.profile,
...


where


class Character(Model):
    user_profile = ForeignKey(UserProfile, related_name='characters')
...


I get a ValueError:

Cannot assign "<django.db.models.fields.related.RelatedManager object
at 0x552b9a0b10>": "Character.user_profile" must be a "UserProfile"
instance.

The user is logged in, and has a UserProfile according to the admin
interface.

TIA
~Simon

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to