{"action":"created","comment":{"url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/pulls/comments/47733251","id":47733251,"diff_hunk":"@@ -19,8 +19,11 @@ def edit\n \n   def update\n     g = Game.find(params[:id])\n-    g.move_piece(params[:game][:origin], params[:game][:destination], params[:id])\n-    render text: 'success'\n+    if g.move_piece(params[:game][:origin], params[:game][:destination], params[:id])\n+      render text: 'success'","path":"app/controllers/games_controller.rb","position":7,"original_position":7,"commit_id":"01941b1686c8a9505aef8eb1dcde3e873358db76","original_commit_id":"01941b1686c8a9505aef8eb1dcde3e873358db76","user":{"login":"AUcod3r","id":14982050,"avatar_url":"https://avatars.githubusercontent.com/u/14982050?v=3","gravatar_id":"","url":"https://api.github.com/users/AUcod3r","html_url":"https://github.com/AUcod3r","followers_url":"https://api.github.com/users/AUcod3r/followers","following_url":"https://api.github.com/users/AUcod3r/following{/other_user}","gists_url":"https://api.github.com/users/AUcod3r/gists{/gist_id}","starred_url":"https://api.github.com/users/AUcod3r/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/AUcod3r/subscriptions","organizations_url":"https://api.github.com/users/AUcod3r/orgs","repos_url":"https://api.github.com/users/AUcod3r/repos","events_url":"https://api.github.com/users/AUcod3r/events{/privacy}","received_events_url":"https://api.github.com/users/AUcod3r/received_events","type":"User","site_admin":false},"body":"@hoitomt so this is going back to the jQuery for our board.  How do I need to change the game.js to make these changes?","created_at":"2015-12-16T03:30:00Z","updated_at":"2015-12-16T03:30:00Z","html_url":"https://github.com/weapons-of-mass-deduction/chess-app/pull/20#discussion_r47733251","pull_request_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/pulls/20","_links":{"self":{"href":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/pulls/comments/47733251"},"html":{"href":"https://github.com/weapons-of-mass-deduction/chess-app/pull/20#discussion_r47733251"},"pull_request":{"href":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/pulls/20"}}},"pull_request":{"url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/pulls/20","id":53792576,"html_url":"https://github.com/weapons-of-mass-deduction/chess-app/pull/20","diff_url":"https://github.com/weapons-of-mass-deduction/chess-app/pull/20.diff","patch_url":"https://github.com/weapons-of-mass-deduction/chess-app/pull/20.patch","issue_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/issues/20","number":20,"state":"open","locked":false,"title":"Rook move","user":{"login":"AUcod3r","id":14982050,"avatar_url":"https://avatars.githubusercontent.com/u/14982050?v=3","gravatar_id":"","url":"https://api.github.com/users/AUcod3r","html_url":"https://github.com/AUcod3r","followers_url":"https://api.github.com/users/AUcod3r/followers","following_url":"https://api.github.com/users/AUcod3r/following{/other_user}","gists_url":"https://api.github.com/users/AUcod3r/gists{/gist_id}","starred_url":"https://api.github.com/users/AUcod3r/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/AUcod3r/subscriptions","organizations_url":"https://api.github.com/users/AUcod3r/orgs","repos_url":"https://api.github.com/users/AUcod3r/repos","events_url":"https://api.github.com/users/AUcod3r/events{/privacy}","received_events_url":"https://api.github.com/users/AUcod3r/received_events","type":"User","site_admin":false},"body":"Ok, I added the logic for checking valid moves for the rook.  In the process I had to modify the games controller to render 'nil' if the move wasn't valid so that our board wouldn't change.  Also, had to change some of our variables to instance variables so that they were available to the rook.rb file within which I did the check.  Database updates correctly for valid rook moves.  It doesn't include obstructions check, just that the rook can move along the x and y axis of the board.","created_at":"2015-12-16T02:43:38Z","updated_at":"2015-12-16T03:30:00Z","closed_at":null,"merged_at":null,"merge_commit_sha":"4c4fa65e8df3a127c08bf843ad86c4462bcbd896","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/pulls/20/commits","review_comments_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/pulls/20/comments","review_comment_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/pulls/comments{/number}","comments_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/issues/20/comments","statuses_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/statuses/01941b1686c8a9505aef8eb1dcde3e873358db76","head":{"label":"weapons-of-mass-deduction:rook_move","ref":"rook_move","sha":"01941b1686c8a9505aef8eb1dcde3e873358db76","user":{"login":"weapons-of-mass-deduction","id":15993560,"avatar_url":"https://avatars.githubusercontent.com/u/15993560?v=3","gravatar_id":"","url":"https://api.github.com/users/weapons-of-mass-deduction","html_url":"https://github.com/weapons-of-mass-deduction","followers_url":"https://api.github.com/users/weapons-of-mass-deduction/followers","following_url":"https://api.github.com/users/weapons-of-mass-deduction/following{/other_user}","gists_url":"https://api.github.com/users/weapons-of-mass-deduction/gists{/gist_id}","starred_url":"https://api.github.com/users/weapons-of-mass-deduction/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/weapons-of-mass-deduction/subscriptions","organizations_url":"https://api.github.com/users/weapons-of-mass-deduction/orgs","repos_url":"https://api.github.com/users/weapons-of-mass-deduction/repos","events_url":"https://api.github.com/users/weapons-of-mass-deduction/events{/privacy}","received_events_url":"https://api.github.com/users/weapons-of-mass-deduction/received_events","type":"Organization","site_admin":false},"repo":{"id":46823774,"name":"chess-app","full_name":"weapons-of-mass-deduction/chess-app","owner":{"login":"weapons-of-mass-deduction","id":15993560,"avatar_url":"https://avatars.githubusercontent.com/u/15993560?v=3","gravatar_id":"","url":"https://api.github.com/users/weapons-of-mass-deduction","html_url":"https://github.com/weapons-of-mass-deduction","followers_url":"https://api.github.com/users/weapons-of-mass-deduction/followers","following_url":"https://api.github.com/users/weapons-of-mass-deduction/following{/other_user}","gists_url":"https://api.github.com/users/weapons-of-mass-deduction/gists{/gist_id}","starred_url":"https://api.github.com/users/weapons-of-mass-deduction/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/weapons-of-mass-deduction/subscriptions","organizations_url":"https://api.github.com/users/weapons-of-mass-deduction/orgs","repos_url":"https://api.github.com/users/weapons-of-mass-deduction/repos","events_url":"https://api.github.com/users/weapons-of-mass-deduction/events{/privacy}","received_events_url":"https://api.github.com/users/weapons-of-mass-deduction/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/weapons-of-mass-deduction/chess-app","description":"","fork":false,"url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app","forks_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/forks","keys_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/keys{/key_id}","collaborators_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/teams","hooks_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/hooks","issue_events_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/issues/events{/number}","events_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/events","assignees_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/assignees{/user}","branches_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/branches{/branch}","tags_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/tags","blobs_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/git/refs{/sha}","trees_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/git/trees{/sha}","statuses_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/statuses/{sha}","languages_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/languages","stargazers_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/stargazers","contributors_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/contributors","subscribers_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/subscribers","subscription_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/subscription","commits_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/commits{/sha}","git_commits_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/git/commits{/sha}","comments_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/comments{/number}","issue_comment_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/issues/comments{/number}","contents_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/contents/{+path}","compare_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/compare/{base}...{head}","merges_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/merges","archive_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/downloads","issues_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/issues{/number}","pulls_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/pulls{/number}","milestones_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/milestones{/number}","notifications_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/labels{/name}","releases_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/releases{/id}","created_at":"2015-11-24T22:53:23Z","updated_at":"2015-11-24T23:04:05Z","pushed_at":"2015-12-16T02:43:38Z","git_url":"git://github.com/weapons-of-mass-deduction/chess-app.git","ssh_url":"git@github.com:weapons-of-mass-deduction/chess-app.git","clone_url":"https://github.com/weapons-of-mass-deduction/chess-app.git","svn_url":"https://github.com/weapons-of-mass-deduction/chess-app","homepage":null,"size":1764,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"base":{"label":"weapons-of-mass-deduction:master","ref":"master","sha":"2384b29e446a37e6004adf3cb4c009b3d448b367","user":{"login":"weapons-of-mass-deduction","id":15993560,"avatar_url":"https://avatars.githubusercontent.com/u/15993560?v=3","gravatar_id":"","url":"https://api.github.com/users/weapons-of-mass-deduction","html_url":"https://github.com/weapons-of-mass-deduction","followers_url":"https://api.github.com/users/weapons-of-mass-deduction/followers","following_url":"https://api.github.com/users/weapons-of-mass-deduction/following{/other_user}","gists_url":"https://api.github.com/users/weapons-of-mass-deduction/gists{/gist_id}","starred_url":"https://api.github.com/users/weapons-of-mass-deduction/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/weapons-of-mass-deduction/subscriptions","organizations_url":"https://api.github.com/users/weapons-of-mass-deduction/orgs","repos_url":"https://api.github.com/users/weapons-of-mass-deduction/repos","events_url":"https://api.github.com/users/weapons-of-mass-deduction/events{/privacy}","received_events_url":"https://api.github.com/users/weapons-of-mass-deduction/received_events","type":"Organization","site_admin":false},"repo":{"id":46823774,"name":"chess-app","full_name":"weapons-of-mass-deduction/chess-app","owner":{"login":"weapons-of-mass-deduction","id":15993560,"avatar_url":"https://avatars.githubusercontent.com/u/15993560?v=3","gravatar_id":"","url":"https://api.github.com/users/weapons-of-mass-deduction","html_url":"https://github.com/weapons-of-mass-deduction","followers_url":"https://api.github.com/users/weapons-of-mass-deduction/followers","following_url":"https://api.github.com/users/weapons-of-mass-deduction/following{/other_user}","gists_url":"https://api.github.com/users/weapons-of-mass-deduction/gists{/gist_id}","starred_url":"https://api.github.com/users/weapons-of-mass-deduction/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/weapons-of-mass-deduction/subscriptions","organizations_url":"https://api.github.com/users/weapons-of-mass-deduction/orgs","repos_url":"https://api.github.com/users/weapons-of-mass-deduction/repos","events_url":"https://api.github.com/users/weapons-of-mass-deduction/events{/privacy}","received_events_url":"https://api.github.com/users/weapons-of-mass-deduction/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/weapons-of-mass-deduction/chess-app","description":"","fork":false,"url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app","forks_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/forks","keys_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/keys{/key_id}","collaborators_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/teams","hooks_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/hooks","issue_events_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/issues/events{/number}","events_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/events","assignees_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/assignees{/user}","branches_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/branches{/branch}","tags_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/tags","blobs_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/git/refs{/sha}","trees_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/git/trees{/sha}","statuses_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/statuses/{sha}","languages_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/languages","stargazers_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/stargazers","contributors_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/contributors","subscribers_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/subscribers","subscription_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/subscription","commits_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/commits{/sha}","git_commits_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/git/commits{/sha}","comments_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/comments{/number}","issue_comment_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/issues/comments{/number}","contents_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/contents/{+path}","compare_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/compare/{base}...{head}","merges_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/merges","archive_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/downloads","issues_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/issues{/number}","pulls_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/pulls{/number}","milestones_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/milestones{/number}","notifications_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/labels{/name}","releases_url":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/releases{/id}","created_at":"2015-11-24T22:53:23Z","updated_at":"2015-11-24T23:04:05Z","pushed_at":"2015-12-16T02:43:38Z","git_url":"git://github.com/weapons-of-mass-deduction/chess-app.git","ssh_url":"git@github.com:weapons-of-mass-deduction/chess-app.git","clone_url":"https://github.com/weapons-of-mass-deduction/chess-app.git","svn_url":"https://github.com/weapons-of-mass-deduction/chess-app","homepage":null,"size":1764,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/pulls/20"},"html":{"href":"https://github.com/weapons-of-mass-deduction/chess-app/pull/20"},"issue":{"href":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/issues/20"},"comments":{"href":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/issues/20/comments"},"review_comments":{"href":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/pulls/20/comments"},"review_comment":{"href":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/pulls/20/commits"},"statuses":{"href":"https://api.github.com/repos/weapons-of-mass-deduction/chess-app/statuses/01941b1686c8a9505aef8eb1dcde3e873358db76"}}}}