{"action":"created","comment":{"url":"https://api.github.com/repos/cluhring/the_pivot/pulls/comments/25379723","id":25379723,"diff_hunk":"@@ -14,7 +14,18 @@ def index\n   def destroy\n     @reservation = Reservation.find(params[:id])\n     if @reservation.destroy\n-      flash[:notice] = \"Reservation successfully cancelled\"\n+      flash[:notice] = \"Reservation successfully deleted\"\n+      redirect_to :back\n+    end\n+  end\n+\n+  def update\n+    @reservation = Reservation.find(params[:id])\n+    if @reservation.update(status: params[:status])\n+      flash[:notice] = \"Reservation successfully changed to #{params[:status]}\"\n+      redirect_to :back\n+    else\n+      flash[:notice] = \"Reservation status could not be updated\"","path":"app/controllers/user/reservations_controller.rb","position":16,"original_position":16,"commit_id":"cf8c04b9dc8408b6590e2db4642d245b6a136ea9","original_commit_id":"cf8c04b9dc8408b6590e2db4642d245b6a136ea9","user":{"login":"kpearson","id":3293289,"avatar_url":"https://avatars.githubusercontent.com/u/3293289?v=3","gravatar_id":"","url":"https://api.github.com/users/kpearson","html_url":"https://github.com/kpearson","followers_url":"https://api.github.com/users/kpearson/followers","following_url":"https://api.github.com/users/kpearson/following{/other_user}","gists_url":"https://api.github.com/users/kpearson/gists{/gist_id}","starred_url":"https://api.github.com/users/kpearson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kpearson/subscriptions","organizations_url":"https://api.github.com/users/kpearson/orgs","repos_url":"https://api.github.com/users/kpearson/repos","events_url":"https://api.github.com/users/kpearson/events{/privacy}","received_events_url":"https://api.github.com/users/kpearson/received_events","type":"User","site_admin":false},"body":"Thats a beautiful thing.","created_at":"2015-02-25T21:16:42Z","updated_at":"2015-02-25T21:16:42Z","html_url":"https://github.com/cluhring/the_pivot/pull/119#discussion_r25379723","pull_request_url":"https://api.github.com/repos/cluhring/the_pivot/pulls/119","_links":{"self":{"href":"https://api.github.com/repos/cluhring/the_pivot/pulls/comments/25379723"},"html":{"href":"https://github.com/cluhring/the_pivot/pull/119#discussion_r25379723"},"pull_request":{"href":"https://api.github.com/repos/cluhring/the_pivot/pulls/119"}}},"pull_request":{"url":"https://api.github.com/repos/cluhring/the_pivot/pulls/119","id":30016340,"html_url":"https://github.com/cluhring/the_pivot/pull/119","diff_url":"https://github.com/cluhring/the_pivot/pull/119.diff","patch_url":"https://github.com/cluhring/the_pivot/pull/119.patch","issue_url":"https://api.github.com/repos/cluhring/the_pivot/issues/119","number":119,"state":"open","locked":false,"title":"Host can approve cancel requests","user":{"login":"bryceholcomb","id":6202829,"avatar_url":"https://avatars.githubusercontent.com/u/6202829?v=3","gravatar_id":"","url":"https://api.github.com/users/bryceholcomb","html_url":"https://github.com/bryceholcomb","followers_url":"https://api.github.com/users/bryceholcomb/followers","following_url":"https://api.github.com/users/bryceholcomb/following{/other_user}","gists_url":"https://api.github.com/users/bryceholcomb/gists{/gist_id}","starred_url":"https://api.github.com/users/bryceholcomb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bryceholcomb/subscriptions","organizations_url":"https://api.github.com/users/bryceholcomb/orgs","repos_url":"https://api.github.com/users/bryceholcomb/repos","events_url":"https://api.github.com/users/bryceholcomb/events{/privacy}","received_events_url":"https://api.github.com/users/bryceholcomb/received_events","type":"User","site_admin":false},"body":"","created_at":"2015-02-25T19:18:16Z","updated_at":"2015-02-25T21:16:42Z","closed_at":null,"merged_at":null,"merge_commit_sha":"8b24893b86fd12623ff781659575696c6db7bac5","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/cluhring/the_pivot/pulls/119/commits","review_comments_url":"https://api.github.com/repos/cluhring/the_pivot/pulls/119/comments","review_comment_url":"https://api.github.com/repos/cluhring/the_pivot/pulls/comments{/number}","comments_url":"https://api.github.com/repos/cluhring/the_pivot/issues/119/comments","statuses_url":"https://api.github.com/repos/cluhring/the_pivot/statuses/cf8c04b9dc8408b6590e2db4642d245b6a136ea9","head":{"label":"cluhring:host-can-approve-cancel-requests","ref":"host-can-approve-cancel-requests","sha":"cf8c04b9dc8408b6590e2db4642d245b6a136ea9","user":{"login":"cluhring","id":8466906,"avatar_url":"https://avatars.githubusercontent.com/u/8466906?v=3","gravatar_id":"","url":"https://api.github.com/users/cluhring","html_url":"https://github.com/cluhring","followers_url":"https://api.github.com/users/cluhring/followers","following_url":"https://api.github.com/users/cluhring/following{/other_user}","gists_url":"https://api.github.com/users/cluhring/gists{/gist_id}","starred_url":"https://api.github.com/users/cluhring/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cluhring/subscriptions","organizations_url":"https://api.github.com/users/cluhring/orgs","repos_url":"https://api.github.com/users/cluhring/repos","events_url":"https://api.github.com/users/cluhring/events{/privacy}","received_events_url":"https://api.github.com/users/cluhring/received_events","type":"User","site_admin":false},"repo":{"id":30557499,"name":"the_pivot","full_name":"cluhring/the_pivot","owner":{"login":"cluhring","id":8466906,"avatar_url":"https://avatars.githubusercontent.com/u/8466906?v=3","gravatar_id":"","url":"https://api.github.com/users/cluhring","html_url":"https://github.com/cluhring","followers_url":"https://api.github.com/users/cluhring/followers","following_url":"https://api.github.com/users/cluhring/following{/other_user}","gists_url":"https://api.github.com/users/cluhring/gists{/gist_id}","starred_url":"https://api.github.com/users/cluhring/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cluhring/subscriptions","organizations_url":"https://api.github.com/users/cluhring/orgs","repos_url":"https://api.github.com/users/cluhring/repos","events_url":"https://api.github.com/users/cluhring/events{/privacy}","received_events_url":"https://api.github.com/users/cluhring/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/cluhring/the_pivot","description":"Lydia, Bryce, Kit and Chris Pivot Dinner Dash into Travel Home","fork":false,"url":"https://api.github.com/repos/cluhring/the_pivot","forks_url":"https://api.github.com/repos/cluhring/the_pivot/forks","keys_url":"https://api.github.com/repos/cluhring/the_pivot/keys{/key_id}","collaborators_url":"https://api.github.com/repos/cluhring/the_pivot/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/cluhring/the_pivot/teams","hooks_url":"https://api.github.com/repos/cluhring/the_pivot/hooks","issue_events_url":"https://api.github.com/repos/cluhring/the_pivot/issues/events{/number}","events_url":"https://api.github.com/repos/cluhring/the_pivot/events","assignees_url":"https://api.github.com/repos/cluhring/the_pivot/assignees{/user}","branches_url":"https://api.github.com/repos/cluhring/the_pivot/branches{/branch}","tags_url":"https://api.github.com/repos/cluhring/the_pivot/tags","blobs_url":"https://api.github.com/repos/cluhring/the_pivot/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/cluhring/the_pivot/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/cluhring/the_pivot/git/refs{/sha}","trees_url":"https://api.github.com/repos/cluhring/the_pivot/git/trees{/sha}","statuses_url":"https://api.github.com/repos/cluhring/the_pivot/statuses/{sha}","languages_url":"https://api.github.com/repos/cluhring/the_pivot/languages","stargazers_url":"https://api.github.com/repos/cluhring/the_pivot/stargazers","contributors_url":"https://api.github.com/repos/cluhring/the_pivot/contributors","subscribers_url":"https://api.github.com/repos/cluhring/the_pivot/subscribers","subscription_url":"https://api.github.com/repos/cluhring/the_pivot/subscription","commits_url":"https://api.github.com/repos/cluhring/the_pivot/commits{/sha}","git_commits_url":"https://api.github.com/repos/cluhring/the_pivot/git/commits{/sha}","comments_url":"https://api.github.com/repos/cluhring/the_pivot/comments{/number}","issue_comment_url":"https://api.github.com/repos/cluhring/the_pivot/issues/comments{/number}","contents_url":"https://api.github.com/repos/cluhring/the_pivot/contents/{+path}","compare_url":"https://api.github.com/repos/cluhring/the_pivot/compare/{base}...{head}","merges_url":"https://api.github.com/repos/cluhring/the_pivot/merges","archive_url":"https://api.github.com/repos/cluhring/the_pivot/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/cluhring/the_pivot/downloads","issues_url":"https://api.github.com/repos/cluhring/the_pivot/issues{/number}","pulls_url":"https://api.github.com/repos/cluhring/the_pivot/pulls{/number}","milestones_url":"https://api.github.com/repos/cluhring/the_pivot/milestones{/number}","notifications_url":"https://api.github.com/repos/cluhring/the_pivot/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/cluhring/the_pivot/labels{/name}","releases_url":"https://api.github.com/repos/cluhring/the_pivot/releases{/id}","created_at":"2015-02-09T20:43:51Z","updated_at":"2015-02-25T21:03:06Z","pushed_at":"2015-02-25T21:10:11Z","git_url":"git://github.com/cluhring/the_pivot.git","ssh_url":"git@github.com:cluhring/the_pivot.git","clone_url":"https://github.com/cluhring/the_pivot.git","svn_url":"https://github.com/cluhring/the_pivot","homepage":null,"size":48203,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":42,"forks":2,"open_issues":42,"watchers":0,"default_branch":"master"}},"base":{"label":"cluhring:master","ref":"master","sha":"2416825fc8e609ab5b706626ab5002b4ebff2272","user":{"login":"cluhring","id":8466906,"avatar_url":"https://avatars.githubusercontent.com/u/8466906?v=3","gravatar_id":"","url":"https://api.github.com/users/cluhring","html_url":"https://github.com/cluhring","followers_url":"https://api.github.com/users/cluhring/followers","following_url":"https://api.github.com/users/cluhring/following{/other_user}","gists_url":"https://api.github.com/users/cluhring/gists{/gist_id}","starred_url":"https://api.github.com/users/cluhring/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cluhring/subscriptions","organizations_url":"https://api.github.com/users/cluhring/orgs","repos_url":"https://api.github.com/users/cluhring/repos","events_url":"https://api.github.com/users/cluhring/events{/privacy}","received_events_url":"https://api.github.com/users/cluhring/received_events","type":"User","site_admin":false},"repo":{"id":30557499,"name":"the_pivot","full_name":"cluhring/the_pivot","owner":{"login":"cluhring","id":8466906,"avatar_url":"https://avatars.githubusercontent.com/u/8466906?v=3","gravatar_id":"","url":"https://api.github.com/users/cluhring","html_url":"https://github.com/cluhring","followers_url":"https://api.github.com/users/cluhring/followers","following_url":"https://api.github.com/users/cluhring/following{/other_user}","gists_url":"https://api.github.com/users/cluhring/gists{/gist_id}","starred_url":"https://api.github.com/users/cluhring/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cluhring/subscriptions","organizations_url":"https://api.github.com/users/cluhring/orgs","repos_url":"https://api.github.com/users/cluhring/repos","events_url":"https://api.github.com/users/cluhring/events{/privacy}","received_events_url":"https://api.github.com/users/cluhring/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/cluhring/the_pivot","description":"Lydia, Bryce, Kit and Chris Pivot Dinner Dash into Travel Home","fork":false,"url":"https://api.github.com/repos/cluhring/the_pivot","forks_url":"https://api.github.com/repos/cluhring/the_pivot/forks","keys_url":"https://api.github.com/repos/cluhring/the_pivot/keys{/key_id}","collaborators_url":"https://api.github.com/repos/cluhring/the_pivot/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/cluhring/the_pivot/teams","hooks_url":"https://api.github.com/repos/cluhring/the_pivot/hooks","issue_events_url":"https://api.github.com/repos/cluhring/the_pivot/issues/events{/number}","events_url":"https://api.github.com/repos/cluhring/the_pivot/events","assignees_url":"https://api.github.com/repos/cluhring/the_pivot/assignees{/user}","branches_url":"https://api.github.com/repos/cluhring/the_pivot/branches{/branch}","tags_url":"https://api.github.com/repos/cluhring/the_pivot/tags","blobs_url":"https://api.github.com/repos/cluhring/the_pivot/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/cluhring/the_pivot/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/cluhring/the_pivot/git/refs{/sha}","trees_url":"https://api.github.com/repos/cluhring/the_pivot/git/trees{/sha}","statuses_url":"https://api.github.com/repos/cluhring/the_pivot/statuses/{sha}","languages_url":"https://api.github.com/repos/cluhring/the_pivot/languages","stargazers_url":"https://api.github.com/repos/cluhring/the_pivot/stargazers","contributors_url":"https://api.github.com/repos/cluhring/the_pivot/contributors","subscribers_url":"https://api.github.com/repos/cluhring/the_pivot/subscribers","subscription_url":"https://api.github.com/repos/cluhring/the_pivot/subscription","commits_url":"https://api.github.com/repos/cluhring/the_pivot/commits{/sha}","git_commits_url":"https://api.github.com/repos/cluhring/the_pivot/git/commits{/sha}","comments_url":"https://api.github.com/repos/cluhring/the_pivot/comments{/number}","issue_comment_url":"https://api.github.com/repos/cluhring/the_pivot/issues/comments{/number}","contents_url":"https://api.github.com/repos/cluhring/the_pivot/contents/{+path}","compare_url":"https://api.github.com/repos/cluhring/the_pivot/compare/{base}...{head}","merges_url":"https://api.github.com/repos/cluhring/the_pivot/merges","archive_url":"https://api.github.com/repos/cluhring/the_pivot/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/cluhring/the_pivot/downloads","issues_url":"https://api.github.com/repos/cluhring/the_pivot/issues{/number}","pulls_url":"https://api.github.com/repos/cluhring/the_pivot/pulls{/number}","milestones_url":"https://api.github.com/repos/cluhring/the_pivot/milestones{/number}","notifications_url":"https://api.github.com/repos/cluhring/the_pivot/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/cluhring/the_pivot/labels{/name}","releases_url":"https://api.github.com/repos/cluhring/the_pivot/releases{/id}","created_at":"2015-02-09T20:43:51Z","updated_at":"2015-02-25T21:03:06Z","pushed_at":"2015-02-25T21:10:11Z","git_url":"git://github.com/cluhring/the_pivot.git","ssh_url":"git@github.com:cluhring/the_pivot.git","clone_url":"https://github.com/cluhring/the_pivot.git","svn_url":"https://github.com/cluhring/the_pivot","homepage":null,"size":48203,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":42,"forks":2,"open_issues":42,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/cluhring/the_pivot/pulls/119"},"html":{"href":"https://github.com/cluhring/the_pivot/pull/119"},"issue":{"href":"https://api.github.com/repos/cluhring/the_pivot/issues/119"},"comments":{"href":"https://api.github.com/repos/cluhring/the_pivot/issues/119/comments"},"review_comments":{"href":"https://api.github.com/repos/cluhring/the_pivot/pulls/119/comments"},"review_comment":{"href":"https://api.github.com/repos/cluhring/the_pivot/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/cluhring/the_pivot/pulls/119/commits"},"statuses":{"href":"https://api.github.com/repos/cluhring/the_pivot/statuses/cf8c04b9dc8408b6590e2db4642d245b6a136ea9"}}}}