{"action":"created","issue":{"url":"https://api.github.com/repos/alphagov/specialist-publisher-rebuild/issues/513","repository_url":"https://api.github.com/repos/alphagov/specialist-publisher-rebuild","labels_url":"https://api.github.com/repos/alphagov/specialist-publisher-rebuild/issues/513/labels{/name}","comments_url":"https://api.github.com/repos/alphagov/specialist-publisher-rebuild/issues/513/comments","events_url":"https://api.github.com/repos/alphagov/specialist-publisher-rebuild/issues/513/events","html_url":"https://github.com/alphagov/specialist-publisher-rebuild/issues/513","id":147102018,"number":513,"title":"[CLOSED] Gracefully handle manuals that can't be found","user":{"login":"benilovj","id":23801,"avatar_url":"https://avatars.githubusercontent.com/u/23801?v=3","gravatar_id":"","url":"https://api.github.com/users/benilovj","html_url":"https://github.com/benilovj","followers_url":"https://api.github.com/users/benilovj/followers","following_url":"https://api.github.com/users/benilovj/following{/other_user}","gists_url":"https://api.github.com/users/benilovj/gists{/gist_id}","starred_url":"https://api.github.com/users/benilovj/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/benilovj/subscriptions","organizations_url":"https://api.github.com/users/benilovj/orgs","repos_url":"https://api.github.com/users/benilovj/repos","events_url":"https://api.github.com/users/benilovj/events{/privacy}","received_events_url":"https://api.github.com/users/benilovj/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2016-04-09T07:28:48Z","updated_at":"2016-04-09T07:28:49Z","closed_at":null,"body":"<a href=\"https://github.com/jamiecobbett\"><img src=\"https://avatars.githubusercontent.com/u/93739?v=3\" align=\"left\" width=\"96\" height=\"96\" hspace=\"10\"></img></a> **Issue by [jamiecobbett](https://github.com/jamiecobbett)**\n_Tuesday 07 July 2015 at 12:09 GMT_\n_Originally opened as https://github.com/alphagov/specialist-publisher/pull/513_\n\n----\n\nPattern copied from app/repositories/specialist_document_repository.rb and\r\napp/controllers/abstract_documents_controller.rb.\r\n\r\nIf you navigate to the path for a manual that doesn't exist in the database, you\r\ncurrently see a generic Rails error page. This happens routinely when a manual\r\nis created in our Preview environment, gets lost when the production => preview\r\ndata sync happens and then a user tries to access it the following day. By\r\nraising a more specific error, we can then catch it and handle it gracefully.\n\n----\n\n_**[jamiecobbett](https://github.com/jamiecobbett)** included the following code: https://github.com/alphagov/specialist-publisher/pull/513/commits_\n"},"comment":{"url":"https://api.github.com/repos/alphagov/specialist-publisher-rebuild/issues/comments/207733764","html_url":"https://github.com/alphagov/specialist-publisher-rebuild/issues/513#issuecomment-207733764","issue_url":"https://api.github.com/repos/alphagov/specialist-publisher-rebuild/issues/513","id":207733764,"user":{"login":"benilovj","id":23801,"avatar_url":"https://avatars.githubusercontent.com/u/23801?v=3","gravatar_id":"","url":"https://api.github.com/users/benilovj","html_url":"https://github.com/benilovj","followers_url":"https://api.github.com/users/benilovj/followers","following_url":"https://api.github.com/users/benilovj/following{/other_user}","gists_url":"https://api.github.com/users/benilovj/gists{/gist_id}","starred_url":"https://api.github.com/users/benilovj/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/benilovj/subscriptions","organizations_url":"https://api.github.com/users/benilovj/orgs","repos_url":"https://api.github.com/users/benilovj/repos","events_url":"https://api.github.com/users/benilovj/events{/privacy}","received_events_url":"https://api.github.com/users/benilovj/received_events","type":"User","site_admin":false},"created_at":"2016-04-09T07:28:49Z","updated_at":"2016-04-09T07:28:49Z","body":"<a href=\"https://github.com/jamiecobbett\"><img src=\"https://avatars.githubusercontent.com/u/93739?v=3\" align=\"left\" width=\"48\" height=\"48\" hspace=\"10\"></img></a> **Comment by [jamiecobbett](https://github.com/jamiecobbett)**\n_Tuesday 07 July 2015 at 12:49 GMT_\n\n----\n\n> We could also display something more specific for \"Manual not found\"?\r\n\r\nI've corrected the copy pasta of \"Document not found\" to \"Manual not found\". Is that what you meant?\n"}}