{"action":"created","issue":{"url":"https://api.github.com/repos/locomotivecms/engine/issues/1038","labels_url":"https://api.github.com/repos/locomotivecms/engine/issues/1038/labels{/name}","comments_url":"https://api.github.com/repos/locomotivecms/engine/issues/1038/comments","events_url":"https://api.github.com/repos/locomotivecms/engine/issues/1038/events","html_url":"https://github.com/locomotivecms/engine/issues/1038","id":65541957,"number":1038,"title":"URL with non-existent locale should 404 or redirect.","user":{"login":"jasongonzales23","id":243861,"avatar_url":"https://avatars.githubusercontent.com/u/243861?v=3","gravatar_id":"","url":"https://api.github.com/users/jasongonzales23","html_url":"https://github.com/jasongonzales23","followers_url":"https://api.github.com/users/jasongonzales23/followers","following_url":"https://api.github.com/users/jasongonzales23/following{/other_user}","gists_url":"https://api.github.com/users/jasongonzales23/gists{/gist_id}","starred_url":"https://api.github.com/users/jasongonzales23/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jasongonzales23/subscriptions","organizations_url":"https://api.github.com/users/jasongonzales23/orgs","repos_url":"https://api.github.com/users/jasongonzales23/repos","events_url":"https://api.github.com/users/jasongonzales23/events{/privacy}","received_events_url":"https://api.github.com/users/jasongonzales23/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-03-31T20:47:50Z","updated_at":"2015-04-14T17:21:46Z","closed_at":null,"body":"To reproduce: \r\n\r\nGo to www.somesite.com/en-fake -> the page should redirect to the default locale homepage.\r\nGo to www.somesite.com/en-fake/page/content_type/:id -> should either 404 or redirect, but instead 500s with the following error:\r\n\r\nNoMethodError: undefined method `children_with_minimal_attributes' for nil:NilClass\r\n\r\nHowever, I also get 500s if I hit a page that doesn't rely on a content_type.\r\n\r\nI'm seeing this in production of our website where users are trying to hit a locale we no longer support (it's turned off in the admin and removed from site.yml, there are no longer templates for it). But if I just make up any old local, I get the same errors."},"comment":{"url":"https://api.github.com/repos/locomotivecms/engine/issues/comments/92987716","html_url":"https://github.com/locomotivecms/engine/issues/1038#issuecomment-92987716","issue_url":"https://api.github.com/repos/locomotivecms/engine/issues/1038","id":92987716,"user":{"login":"jasongonzales23","id":243861,"avatar_url":"https://avatars.githubusercontent.com/u/243861?v=3","gravatar_id":"","url":"https://api.github.com/users/jasongonzales23","html_url":"https://github.com/jasongonzales23","followers_url":"https://api.github.com/users/jasongonzales23/followers","following_url":"https://api.github.com/users/jasongonzales23/following{/other_user}","gists_url":"https://api.github.com/users/jasongonzales23/gists{/gist_id}","starred_url":"https://api.github.com/users/jasongonzales23/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jasongonzales23/subscriptions","organizations_url":"https://api.github.com/users/jasongonzales23/orgs","repos_url":"https://api.github.com/users/jasongonzales23/repos","events_url":"https://api.github.com/users/jasongonzales23/events{/privacy}","received_events_url":"https://api.github.com/users/jasongonzales23/received_events","type":"User","site_admin":false},"created_at":"2015-04-14T17:21:46Z","updated_at":"2015-04-14T17:21:46Z","body":"Bump. Still getting hella 500s out here."}}