title: Django 1.8.2: Passing a data object to User.objects.create_user
body: <p>Is there a way you can pass an instance of object (from Python) to the create_user method when creating a user on Django?</p>
  
  <p>What I mean is, suppose that I want to let the user decide whether to include a first name, a last name, both, or neither. An e-mail address is optional too.</p>
  
  <p>Suppose I create a Python object as follows:</p>
  
  <pre><code>data = {first_name = 'Howdy', last_name = 'Hilary', email: 'hhilary@gmail.com}
  </code></pre>
  
  <p>Then I pass it as follows:</p>
  
  <pre><code>user = User.objects.create_user(username = 'jdsflsdf', password = '********', data)
  </code></pre>
  
  <p>Is this possible or no? I'm trying to see if there's a simpler way of creating a user on Django in different sign-up circumstances without having to rely on multiple if-else-if clauses.</p>
  
  <p>(Well, I did try implementing this in the shell, except that I got a syntax error and had trouble finding out which character it was pointing to since my Command Prompt window was only limited to 80 characters in width. I tried again in a separate Python window shell, except I got an error for not setting the Environment Variable initially, and did not want to make a change to it because it's so delicate to do. I don't even know if setting Environment Variables only affects the Command Prompt.)</p>