{"action":"created","issue":{"url":"https://api.github.com/repos/medic/medic-api/issues/51","repository_url":"https://api.github.com/repos/medic/medic-api","labels_url":"https://api.github.com/repos/medic/medic-api/issues/51/labels{/name}","comments_url":"https://api.github.com/repos/medic/medic-api/issues/51/comments","events_url":"https://api.github.com/repos/medic/medic-api/issues/51/events","html_url":"https://github.com/medic/medic-api/pull/51","id":141408077,"number":51,"title":"added update support to users controller. ","user":{"login":"mandric","id":25641,"avatar_url":"https://avatars.githubusercontent.com/u/25641?v=3","gravatar_id":"","url":"https://api.github.com/users/mandric","html_url":"https://github.com/mandric","followers_url":"https://api.github.com/users/mandric/followers","following_url":"https://api.github.com/users/mandric/following{/other_user}","gists_url":"https://api.github.com/users/mandric/gists{/gist_id}","starred_url":"https://api.github.com/users/mandric/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mandric/subscriptions","organizations_url":"https://api.github.com/users/mandric/orgs","repos_url":"https://api.github.com/users/mandric/repos","events_url":"https://api.github.com/users/mandric/events{/privacy}","received_events_url":"https://api.github.com/users/mandric/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2016-03-16T21:31:19Z","updated_at":"2016-03-23T00:21:42Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/medic/medic-api/pulls/51","html_url":"https://github.com/medic/medic-api/pull/51","diff_url":"https://github.com/medic/medic-api/pull/51.diff","patch_url":"https://github.com/medic/medic-api/pull/51.patch"},"body":"WIP medic/medic-webapp#2047\r\n\r\nDo we want to enforce password-strength standards?\r\n\r\nCouple weird errors to end user below... not sure if this is acceptable.\r\n\r\nPlace not found error:\r\n```\r\ncurl -X POST -H 'content-type:application/json' -d '{\"place\":\"blah\"}' 'http://admin:secret@localhost:5988/api/v1/users/henry'\r\nServer error: missing\r\n```\r\n\r\nWhen type is not in the list of supported types (see User Types list in doc). Type not found error:\r\n```\r\ncurl -X POST -H 'content-type:application/json' -d '{\"type\":\"blah\"}' 'http://admin:secret@localhost:5988/api/v1/users/henry'\r\nServer error: doc.roles can only contain strings\r\n```"},"comment":{"url":"https://api.github.com/repos/medic/medic-api/issues/comments/200091806","html_url":"https://github.com/medic/medic-api/pull/51#issuecomment-200091806","issue_url":"https://api.github.com/repos/medic/medic-api/issues/51","id":200091806,"user":{"login":"garethbowen","id":2064938,"avatar_url":"https://avatars.githubusercontent.com/u/2064938?v=3","gravatar_id":"","url":"https://api.github.com/users/garethbowen","html_url":"https://github.com/garethbowen","followers_url":"https://api.github.com/users/garethbowen/followers","following_url":"https://api.github.com/users/garethbowen/following{/other_user}","gists_url":"https://api.github.com/users/garethbowen/gists{/gist_id}","starred_url":"https://api.github.com/users/garethbowen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/garethbowen/subscriptions","organizations_url":"https://api.github.com/users/garethbowen/orgs","repos_url":"https://api.github.com/users/garethbowen/repos","events_url":"https://api.github.com/users/garethbowen/events{/privacy}","received_events_url":"https://api.github.com/users/garethbowen/received_events","type":"User","site_admin":false},"created_at":"2016-03-23T00:21:42Z","updated_at":"2016-03-23T00:21:42Z","body":"> Do we save roles on both docs (user and user-settings)? \r\n\r\nYes we have to. Save on `user` because `user-settings` can't be trusted as it can be modified client side. Save on `user-settings` because `user` can't be replicated and we need to be able to read it client side.\r\n\r\n> 200 http response ok? Do we want a JSON response similar to create?\r\n\r\nA simple JSON response is nice IMO."}}