{"action":"created","issue":{"url":"https://api.github.com/repos/dcr8898/kool-cards/issues/16","labels_url":"https://api.github.com/repos/dcr8898/kool-cards/issues/16/labels{/name}","comments_url":"https://api.github.com/repos/dcr8898/kool-cards/issues/16/comments","events_url":"https://api.github.com/repos/dcr8898/kool-cards/issues/16/events","html_url":"https://github.com/dcr8898/kool-cards/pull/16","id":109627108,"number":16,"title":"Rework game flow to eliminaste unnecessary redirect","user":{"login":"dcr8898","id":12485272,"avatar_url":"https://avatars.githubusercontent.com/u/12485272?v=3","gravatar_id":"","url":"https://api.github.com/users/dcr8898","html_url":"https://github.com/dcr8898","followers_url":"https://api.github.com/users/dcr8898/followers","following_url":"https://api.github.com/users/dcr8898/following{/other_user}","gists_url":"https://api.github.com/users/dcr8898/gists{/gist_id}","starred_url":"https://api.github.com/users/dcr8898/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dcr8898/subscriptions","organizations_url":"https://api.github.com/users/dcr8898/orgs","repos_url":"https://api.github.com/users/dcr8898/repos","events_url":"https://api.github.com/users/dcr8898/events{/privacy}","received_events_url":"https://api.github.com/users/dcr8898/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-10-03T15:14:13Z","updated_at":"2015-10-03T17:17:15Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/dcr8898/kool-cards/pulls/16","html_url":"https://github.com/dcr8898/kool-cards/pull/16","diff_url":"https://github.com/dcr8898/kool-cards/pull/16.diff","patch_url":"https://github.com/dcr8898/kool-cards/pull/16.patch"},"body":"This commit reworks the game flow as follows:\r\n\r\nOld game flow:\r\n1) 'GET /rounds/:round_id' --> erb :'rounds/show' (game summary) OR redirect to /guesses/:guess_id\r\n2) 'GET /guesses/:guess_id' --> erb :'guesses/show' (view card & response form)\r\n3) 'POST /guesses/:guess_id' --> receives answer from previous step, checks answer (with side effects) and redirects to step 1 (GET /rounds/:round_id)\r\n\r\nI wanted to eliminate the double redirects between Steps 3 and 1 during game play.\r\n\r\nNew game flow:\r\n1) 'GET /rounds/:round_id/card' --> erb :'rounds/show' (game summary) OR erb :'rounds/edit' (view card & response form)\r\n2) 'POST /guesses/:guess_id' --> receives answer from previous step, checks answer (with side effects) and redirects to step 1 (GET /rounds/:round_id/card)\r\n\r\nI like this flow better, but I am certainly not married to the route format or the view name (or directory).  I know David wasn't thrilled earlier with a route similar to what I have in step 1, but I am open to changing it--you could change it to anything (e.g., you could just shorten it to '/rounds/:round_id') without changing functionality at all.  The view also seems a little funny to me at 'rounds/edit.'  I think it probably makes the most sense to merge this change as an improvement to the flow, and then discuss if we want to change the route format or view location (easy changes later)."},"comment":{"url":"https://api.github.com/repos/dcr8898/kool-cards/issues/comments/145270086","html_url":"https://github.com/dcr8898/kool-cards/pull/16#issuecomment-145270086","issue_url":"https://api.github.com/repos/dcr8898/kool-cards/issues/16","id":145270086,"user":{"login":"dcr8898","id":12485272,"avatar_url":"https://avatars.githubusercontent.com/u/12485272?v=3","gravatar_id":"","url":"https://api.github.com/users/dcr8898","html_url":"https://github.com/dcr8898","followers_url":"https://api.github.com/users/dcr8898/followers","following_url":"https://api.github.com/users/dcr8898/following{/other_user}","gists_url":"https://api.github.com/users/dcr8898/gists{/gist_id}","starred_url":"https://api.github.com/users/dcr8898/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dcr8898/subscriptions","organizations_url":"https://api.github.com/users/dcr8898/orgs","repos_url":"https://api.github.com/users/dcr8898/repos","events_url":"https://api.github.com/users/dcr8898/events{/privacy}","received_events_url":"https://api.github.com/users/dcr8898/received_events","type":"User","site_admin":false},"created_at":"2015-10-03T17:17:15Z","updated_at":"2015-10-03T17:17:15Z","body":"That makes total sense to me, and I'm all for renaming the view 'cards/show.' My original logic was that you are \"editing\" the round, but it didn't feel exactly right to me either.  I guess another idea would be to use 'guesses/edit' but it really is just an academic debate, since it is just the view name and will never be seen outside of the code.  I have updated the view to be 'cards/show' and I will update this pull request accordingly."}}