RdlP
RdlP

Reputation: 1396

I can't modify User model data in django

When I create a user with (from Shell):

u = User.objects.create_user('Angel', '[email protected]', 'angel')

If then I execute (in the shell):

u.first_name = 'Angel'
u.save

If I see the data base (MySql) I see that the first_name is empty.

Upvotes: 0

Views: 44

Answers (1)

Pavel Anossov
Pavel Anossov

Reputation: 62908

You didn't call save (you forgot the parenthesis):

u.first_name = 'Angel'
u.save()

Upvotes: 4

Related Questions