{"action":"created","issue":{"url":"https://api.github.com/repos/mattermost/platform/issues/960","labels_url":"https://api.github.com/repos/mattermost/platform/issues/960/labels{/name}","comments_url":"https://api.github.com/repos/mattermost/platform/issues/960/comments","events_url":"https://api.github.com/repos/mattermost/platform/issues/960/events","html_url":"https://github.com/mattermost/platform/issues/960","id":110247851,"number":960,"title":"Graceful handling of `Enable Team Creation = false`","user":{"login":"stephenfin","id":1690835,"avatar_url":"https://avatars.githubusercontent.com/u/1690835?v=3","gravatar_id":"","url":"https://api.github.com/users/stephenfin","html_url":"https://github.com/stephenfin","followers_url":"https://api.github.com/users/stephenfin/followers","following_url":"https://api.github.com/users/stephenfin/following{/other_user}","gists_url":"https://api.github.com/users/stephenfin/gists{/gist_id}","starred_url":"https://api.github.com/users/stephenfin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stephenfin/subscriptions","organizations_url":"https://api.github.com/users/stephenfin/orgs","repos_url":"https://api.github.com/users/stephenfin/repos","events_url":"https://api.github.com/users/stephenfin/events{/privacy}","received_events_url":"https://api.github.com/users/stephenfin/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":6,"created_at":"2015-10-07T15:13:49Z","updated_at":"2015-10-07T20:51:23Z","closed_at":null,"body":"When you disable team creation (`SETTINGS` > `Team Settings` > `Enable Team Creation`), entering an email and hitting `Sign Up` on the root page (e.g. `http://mattermost.example.com/`) will not appear to do anything. Investigating this further, you can see an error message in the browsers console:\r\n\r\n```\r\nerror in singupTeam msg=Team creation has been disabled. Please ask your systems administrator for details. detail= rid=788r53uyyprhpf6bgp19w5q4ew\r\n```\r\n\r\nYou can also see this error in Mattermost's log\r\n\r\n```\r\n[2015/10/07 15:27:25 IST] [EROR] /api/v1/teams/signup:isTreamCreationAllowed code=500 rid=kzu8utxqrjrxjcpj3wxr91kn5c uid= ip=10.254.39.18 Team creation has been disabled. Please ask your systems administrator for details. [details: ]\r\n```\r\n\r\nThere are at least four changes required here, plus an optional one that would (strictly IMO, of course) improve usability:\r\n\r\n<ol type='a'>\r\n<li>\r\nAt a minimum, there should be a visual indicator (a toast?) suggesting why the sign up failed. An improvement would be to redirect to a page suggesting why the failure occurred.\r\n</li>\r\n<li>\r\nThe error message should be demoted to a debug - it's too easy to trigger this case and it's really not that important that I should be seeing dozens of red, <code>EROR</code> (sic) class messages in my log: they hide the important stuff\r\n</li>\r\n<li>\r\nI really don't think this should be a <code>HTTP 500 Internal Server Error</code> error. <a href=\"http://www.w3.org/Protocols/HTTP/HTRESP.html\">w3org</a> state that the <code>500</code> status code represents:\r\n\r\n<pre>The server encountered an unexpected condition which prevented it from fulfilling the request.</pre>\r\n\r\nI don't think this is an \"unexpected condition\": we expect it and just don't want to let the user do it. This makes it more akin to a <code>HTTP 403 Forbidden</code>, or:\r\n\r\n<pre>The request is for something forbidden. Authorization will not help.</pre>\r\n\r\nHowever, this is mostly semantics so I could be dead wrong here.\r\n</li>\r\n<li>\r\n<code>:s/EROR/ERROR/g</code> :smile:\r\n</li>\r\n</ol>\r\n\r\nAs for the optional thing, I don't know if this is a feature request or a usability bug. I think (again: strictly IMO here) it would significantly improve usability if you were to change how the \"Sign up\" page works in general. I've found it a pitfall (both for myself and my \"test pool\" of users) that going to this page will encourage you to create a new team when the vast majority of users will instead want to join an existing team (especially within an organisation). If anything, the priority of the \"Sign up\" and \"Find my team\" button/link should be inversed (making this page more akin to a \"Sign in\" page). It would be even better if you could add the ability to view the teams you're part of via the web UI rather than relying on email.\r\n\r\nI'll try working on this and my other issues as soon as I figure out where to start."},"comment":{"url":"https://api.github.com/repos/mattermost/platform/issues/comments/146324244","html_url":"https://github.com/mattermost/platform/issues/960#issuecomment-146324244","issue_url":"https://api.github.com/repos/mattermost/platform/issues/960","id":146324244,"user":{"login":"coreyhulen","id":1431746,"avatar_url":"https://avatars.githubusercontent.com/u/1431746?v=3","gravatar_id":"","url":"https://api.github.com/users/coreyhulen","html_url":"https://github.com/coreyhulen","followers_url":"https://api.github.com/users/coreyhulen/followers","following_url":"https://api.github.com/users/coreyhulen/following{/other_user}","gists_url":"https://api.github.com/users/coreyhulen/gists{/gist_id}","starred_url":"https://api.github.com/users/coreyhulen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/coreyhulen/subscriptions","organizations_url":"https://api.github.com/users/coreyhulen/orgs","repos_url":"https://api.github.com/users/coreyhulen/repos","events_url":"https://api.github.com/users/coreyhulen/events{/privacy}","received_events_url":"https://api.github.com/users/coreyhulen/received_events","type":"User","site_admin":false},"created_at":"2015-10-07T20:51:23Z","updated_at":"2015-10-07T20:51:23Z","body":"I've created https://mattermost.atlassian.net/browse/PLT-565 to track this issue.  Looks like single team is already being tracked as https://mattermost.atlassian.net/browse/PLT-340"}}