Can now make a correct JSONObject
Login adjusted

Login does not see that it failed if cancelled.
Fixed login
cleanup and username key in registry