You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@usergrid.apache.org by "Rod Simpson (JIRA)" <ji...@apache.org> on 2014/01/29 22:50:08 UTC

[jira] [Created] (USERGRID-49) Adding admin user - username seems to default to email address

Rod Simpson created USERGRID-49:
-----------------------------------

             Summary: Adding admin user - username seems to default to email address
                 Key: USERGRID-49
                 URL: https://issues.apache.org/jira/browse/USERGRID-49
             Project: Usergrid
          Issue Type: Bug
          Components: Stack
            Reporter: Rod Simpson


"As reported by a user on the ML, the username field is being populated by the email. Not sure if this is just the JSON returned, or if it is like this in the DB: 

But I think I've found a bug there: 

Here's my request: 
curl -X POST -i -H ""Authorization: Bearer <my_token>"" ""http://<my_usergrid>/management/organizations/<my_org>/users"" -d '{""username"":""beto"",""name"":""fdsafdsal"",""email"":""fdsafdsa@gmail.com"",""password"":""fdsafdsa""}' 


Here's my response: 
{ 
""action"" : ""create user"", 
""status"" : ""ok"", 
""data"" : { 
""user"" : { 
""applicationId"" : ""00000000-0000-0000-0000-000000000001"", 
""username"" : ""fdsafdsa@gmail.com"", 
""name"" : ""fdsafdsa@gmail.com"", 
""email"" : ""fdsafdsa@gmail.com"", 
""activated"" : false, 
""disabled"" : false, 
""properties"" : { }, 
""uuid"" : ""a3b888d4-b68d-11e2-bc11-b7899f6392a4"", 
""adminUser"" : true, 
""displayEmailAddress"" : ""fdsafdsa@gmail.com <al...@gmail.com>"", 
""htmldisplayEmailAddress"" : ""fdsafdsa@gmail.com &lt;<a href=\""mailto:fdsafdsa@gmail.com\"">fdsafdsa@gmail.com</a>&gt;"" 
} 
}, 
""timestamp"" : 1367873022791, 
""duration"" : 432 
} 


Take a look at the ""username"" value. It's getting my email, instead of the username I provided on the request. 
"



--
This message was sent by Atlassian JIRA
(v6.1.5#6160)