{"action":"created","comment":{"url":"https://api.github.com/repos/woojinrichardson/middrides/pulls/comments/230982100","pull_request_review_id":171842608,"id":230982100,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIzMDk4MjEwMA==","diff_hunk":"@@ -12,7 +12,7 @@ class RequestQueue extends Component {\n   componentDidMount() {\n     let requests = [];\n     const db = firebase.firestore();\n-    db.collection('requests').get()\n+    db.collection('requests').where('active', '==', true).get()","path":"src/components/RequestQueue.js","position":5,"original_position":5,"commit_id":"b694aae5d78198ff2e25c96b95e8d6d0497761dc","original_commit_id":"b694aae5d78198ff2e25c96b95e8d6d0497761dc","user":{"login":"sunyang713","id":9291966,"node_id":"MDQ6VXNlcjkyOTE5NjY=","avatar_url":"https://avatars0.githubusercontent.com/u/9291966?v=4","gravatar_id":"","url":"https://api.github.com/users/sunyang713","html_url":"https://github.com/sunyang713","followers_url":"https://api.github.com/users/sunyang713/followers","following_url":"https://api.github.com/users/sunyang713/following{/other_user}","gists_url":"https://api.github.com/users/sunyang713/gists{/gist_id}","starred_url":"https://api.github.com/users/sunyang713/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sunyang713/subscriptions","organizations_url":"https://api.github.com/users/sunyang713/orgs","repos_url":"https://api.github.com/users/sunyang713/repos","events_url":"https://api.github.com/users/sunyang713/events{/privacy}","received_events_url":"https://api.github.com/users/sunyang713/received_events","type":"User","site_admin":false},"body":"If you wanted to be really rigorous with your quality, you would probably want to have some file that defines the schema of your table and put constant strings like \"active\" in there. then you'd write:\r\n```\r\ndb.collection(REQUESTS_TABLE_NAME).where(REQUESTS_TABLE.ACTIVE, '==', true).get()\r\n```\r\nOr however you decide to organize your constants. Though this may be too much for now, so it's a non-blocker.","created_at":"2018-11-06T02:21:45Z","updated_at":"2018-11-06T02:32:07Z","html_url":"https://github.com/woojinrichardson/middrides/pull/1#discussion_r230982100","pull_request_url":"https://api.github.com/repos/woojinrichardson/middrides/pulls/1","author_association":"COLLABORATOR","_links":{"self":{"href":"https://api.github.com/repos/woojinrichardson/middrides/pulls/comments/230982100"},"html":{"href":"https://github.com/woojinrichardson/middrides/pull/1#discussion_r230982100"},"pull_request":{"href":"https://api.github.com/repos/woojinrichardson/middrides/pulls/1"}}},"pull_request":{"url":"https://api.github.com/repos/woojinrichardson/middrides/pulls/1","id":228553097,"node_id":"MDExOlB1bGxSZXF1ZXN0MjI4NTUzMDk3","html_url":"https://github.com/woojinrichardson/middrides/pull/1","diff_url":"https://github.com/woojinrichardson/middrides/pull/1.diff","patch_url":"https://github.com/woojinrichardson/middrides/pull/1.patch","issue_url":"https://api.github.com/repos/woojinrichardson/middrides/issues/1","number":1,"state":"open","locked":false,"title":"Add active property","user":{"login":"woojinrichardson","id":36461846,"node_id":"MDQ6VXNlcjM2NDYxODQ2","avatar_url":"https://avatars0.githubusercontent.com/u/36461846?v=4","gravatar_id":"","url":"https://api.github.com/users/woojinrichardson","html_url":"https://github.com/woojinrichardson","followers_url":"https://api.github.com/users/woojinrichardson/followers","following_url":"https://api.github.com/users/woojinrichardson/following{/other_user}","gists_url":"https://api.github.com/users/woojinrichardson/gists{/gist_id}","starred_url":"https://api.github.com/users/woojinrichardson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/woojinrichardson/subscriptions","organizations_url":"https://api.github.com/users/woojinrichardson/orgs","repos_url":"https://api.github.com/users/woojinrichardson/repos","events_url":"https://api.github.com/users/woojinrichardson/events{/privacy}","received_events_url":"https://api.github.com/users/woojinrichardson/received_events","type":"User","site_admin":false},"body":"This PR adds an `active` Boolean property to requests when they are made. Now, when a user cancels his/her request or when the dispatcher cancels any request, instead of deleting the request in the database, its `active` property is set to `false`. Also, rather than fetching all requests from the database to display them in `RequestQueue`, only active requests are fetched.\r\n\r\n@sunyang713 ","created_at":"2018-11-06T02:10:11Z","updated_at":"2018-11-06T02:32:07Z","closed_at":null,"merged_at":null,"merge_commit_sha":"31f209ee8cff662c739713cce6efe27e38b3dc2f","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/woojinrichardson/middrides/pulls/1/commits","review_comments_url":"https://api.github.com/repos/woojinrichardson/middrides/pulls/1/comments","review_comment_url":"https://api.github.com/repos/woojinrichardson/middrides/pulls/comments{/number}","comments_url":"https://api.github.com/repos/woojinrichardson/middrides/issues/1/comments","statuses_url":"https://api.github.com/repos/woojinrichardson/middrides/statuses/b694aae5d78198ff2e25c96b95e8d6d0497761dc","head":{"label":"woojinrichardson:add-active-property","ref":"add-active-property","sha":"b694aae5d78198ff2e25c96b95e8d6d0497761dc","user":{"login":"woojinrichardson","id":36461846,"node_id":"MDQ6VXNlcjM2NDYxODQ2","avatar_url":"https://avatars0.githubusercontent.com/u/36461846?v=4","gravatar_id":"","url":"https://api.github.com/users/woojinrichardson","html_url":"https://github.com/woojinrichardson","followers_url":"https://api.github.com/users/woojinrichardson/followers","following_url":"https://api.github.com/users/woojinrichardson/following{/other_user}","gists_url":"https://api.github.com/users/woojinrichardson/gists{/gist_id}","starred_url":"https://api.github.com/users/woojinrichardson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/woojinrichardson/subscriptions","organizations_url":"https://api.github.com/users/woojinrichardson/orgs","repos_url":"https://api.github.com/users/woojinrichardson/repos","events_url":"https://api.github.com/users/woojinrichardson/events{/privacy}","received_events_url":"https://api.github.com/users/woojinrichardson/received_events","type":"User","site_admin":false},"repo":{"id":155919670,"node_id":"MDEwOlJlcG9zaXRvcnkxNTU5MTk2NzA=","name":"middrides","full_name":"woojinrichardson/middrides","private":false,"owner":{"login":"woojinrichardson","id":36461846,"node_id":"MDQ6VXNlcjM2NDYxODQ2","avatar_url":"https://avatars0.githubusercontent.com/u/36461846?v=4","gravatar_id":"","url":"https://api.github.com/users/woojinrichardson","html_url":"https://github.com/woojinrichardson","followers_url":"https://api.github.com/users/woojinrichardson/followers","following_url":"https://api.github.com/users/woojinrichardson/following{/other_user}","gists_url":"https://api.github.com/users/woojinrichardson/gists{/gist_id}","starred_url":"https://api.github.com/users/woojinrichardson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/woojinrichardson/subscriptions","organizations_url":"https://api.github.com/users/woojinrichardson/orgs","repos_url":"https://api.github.com/users/woojinrichardson/repos","events_url":"https://api.github.com/users/woojinrichardson/events{/privacy}","received_events_url":"https://api.github.com/users/woojinrichardson/received_events","type":"User","site_admin":false},"html_url":"https://github.com/woojinrichardson/middrides","description":null,"fork":false,"url":"https://api.github.com/repos/woojinrichardson/middrides","forks_url":"https://api.github.com/repos/woojinrichardson/middrides/forks","keys_url":"https://api.github.com/repos/woojinrichardson/middrides/keys{/key_id}","collaborators_url":"https://api.github.com/repos/woojinrichardson/middrides/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/woojinrichardson/middrides/teams","hooks_url":"https://api.github.com/repos/woojinrichardson/middrides/hooks","issue_events_url":"https://api.github.com/repos/woojinrichardson/middrides/issues/events{/number}","events_url":"https://api.github.com/repos/woojinrichardson/middrides/events","assignees_url":"https://api.github.com/repos/woojinrichardson/middrides/assignees{/user}","branches_url":"https://api.github.com/repos/woojinrichardson/middrides/branches{/branch}","tags_url":"https://api.github.com/repos/woojinrichardson/middrides/tags","blobs_url":"https://api.github.com/repos/woojinrichardson/middrides/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/woojinrichardson/middrides/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/woojinrichardson/middrides/git/refs{/sha}","trees_url":"https://api.github.com/repos/woojinrichardson/middrides/git/trees{/sha}","statuses_url":"https://api.github.com/repos/woojinrichardson/middrides/statuses/{sha}","languages_url":"https://api.github.com/repos/woojinrichardson/middrides/languages","stargazers_url":"https://api.github.com/repos/woojinrichardson/middrides/stargazers","contributors_url":"https://api.github.com/repos/woojinrichardson/middrides/contributors","subscribers_url":"https://api.github.com/repos/woojinrichardson/middrides/subscribers","subscription_url":"https://api.github.com/repos/woojinrichardson/middrides/subscription","commits_url":"https://api.github.com/repos/woojinrichardson/middrides/commits{/sha}","git_commits_url":"https://api.github.com/repos/woojinrichardson/middrides/git/commits{/sha}","comments_url":"https://api.github.com/repos/woojinrichardson/middrides/comments{/number}","issue_comment_url":"https://api.github.com/repos/woojinrichardson/middrides/issues/comments{/number}","contents_url":"https://api.github.com/repos/woojinrichardson/middrides/contents/{+path}","compare_url":"https://api.github.com/repos/woojinrichardson/middrides/compare/{base}...{head}","merges_url":"https://api.github.com/repos/woojinrichardson/middrides/merges","archive_url":"https://api.github.com/repos/woojinrichardson/middrides/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/woojinrichardson/middrides/downloads","issues_url":"https://api.github.com/repos/woojinrichardson/middrides/issues{/number}","pulls_url":"https://api.github.com/repos/woojinrichardson/middrides/pulls{/number}","milestones_url":"https://api.github.com/repos/woojinrichardson/middrides/milestones{/number}","notifications_url":"https://api.github.com/repos/woojinrichardson/middrides/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/woojinrichardson/middrides/labels{/name}","releases_url":"https://api.github.com/repos/woojinrichardson/middrides/releases{/id}","deployments_url":"https://api.github.com/repos/woojinrichardson/middrides/deployments","created_at":"2018-11-02T20:44:25Z","updated_at":"2018-11-02T21:33:47Z","pushed_at":"2018-11-06T02:10:11Z","git_url":"git://github.com/woojinrichardson/middrides.git","ssh_url":"git@github.com:woojinrichardson/middrides.git","clone_url":"https://github.com/woojinrichardson/middrides.git","svn_url":"https://github.com/woojinrichardson/middrides","homepage":null,"size":14453,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":1,"license":null,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"base":{"label":"woojinrichardson:master","ref":"master","sha":"803e30d99c5abc0b505f615290a99fb139bb1c84","user":{"login":"woojinrichardson","id":36461846,"node_id":"MDQ6VXNlcjM2NDYxODQ2","avatar_url":"https://avatars0.githubusercontent.com/u/36461846?v=4","gravatar_id":"","url":"https://api.github.com/users/woojinrichardson","html_url":"https://github.com/woojinrichardson","followers_url":"https://api.github.com/users/woojinrichardson/followers","following_url":"https://api.github.com/users/woojinrichardson/following{/other_user}","gists_url":"https://api.github.com/users/woojinrichardson/gists{/gist_id}","starred_url":"https://api.github.com/users/woojinrichardson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/woojinrichardson/subscriptions","organizations_url":"https://api.github.com/users/woojinrichardson/orgs","repos_url":"https://api.github.com/users/woojinrichardson/repos","events_url":"https://api.github.com/users/woojinrichardson/events{/privacy}","received_events_url":"https://api.github.com/users/woojinrichardson/received_events","type":"User","site_admin":false},"repo":{"id":155919670,"node_id":"MDEwOlJlcG9zaXRvcnkxNTU5MTk2NzA=","name":"middrides","full_name":"woojinrichardson/middrides","private":false,"owner":{"login":"woojinrichardson","id":36461846,"node_id":"MDQ6VXNlcjM2NDYxODQ2","avatar_url":"https://avatars0.githubusercontent.com/u/36461846?v=4","gravatar_id":"","url":"https://api.github.com/users/woojinrichardson","html_url":"https://github.com/woojinrichardson","followers_url":"https://api.github.com/users/woojinrichardson/followers","following_url":"https://api.github.com/users/woojinrichardson/following{/other_user}","gists_url":"https://api.github.com/users/woojinrichardson/gists{/gist_id}","starred_url":"https://api.github.com/users/woojinrichardson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/woojinrichardson/subscriptions","organizations_url":"https://api.github.com/users/woojinrichardson/orgs","repos_url":"https://api.github.com/users/woojinrichardson/repos","events_url":"https://api.github.com/users/woojinrichardson/events{/privacy}","received_events_url":"https://api.github.com/users/woojinrichardson/received_events","type":"User","site_admin":false},"html_url":"https://github.com/woojinrichardson/middrides","description":null,"fork":false,"url":"https://api.github.com/repos/woojinrichardson/middrides","forks_url":"https://api.github.com/repos/woojinrichardson/middrides/forks","keys_url":"https://api.github.com/repos/woojinrichardson/middrides/keys{/key_id}","collaborators_url":"https://api.github.com/repos/woojinrichardson/middrides/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/woojinrichardson/middrides/teams","hooks_url":"https://api.github.com/repos/woojinrichardson/middrides/hooks","issue_events_url":"https://api.github.com/repos/woojinrichardson/middrides/issues/events{/number}","events_url":"https://api.github.com/repos/woojinrichardson/middrides/events","assignees_url":"https://api.github.com/repos/woojinrichardson/middrides/assignees{/user}","branches_url":"https://api.github.com/repos/woojinrichardson/middrides/branches{/branch}","tags_url":"https://api.github.com/repos/woojinrichardson/middrides/tags","blobs_url":"https://api.github.com/repos/woojinrichardson/middrides/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/woojinrichardson/middrides/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/woojinrichardson/middrides/git/refs{/sha}","trees_url":"https://api.github.com/repos/woojinrichardson/middrides/git/trees{/sha}","statuses_url":"https://api.github.com/repos/woojinrichardson/middrides/statuses/{sha}","languages_url":"https://api.github.com/repos/woojinrichardson/middrides/languages","stargazers_url":"https://api.github.com/repos/woojinrichardson/middrides/stargazers","contributors_url":"https://api.github.com/repos/woojinrichardson/middrides/contributors","subscribers_url":"https://api.github.com/repos/woojinrichardson/middrides/subscribers","subscription_url":"https://api.github.com/repos/woojinrichardson/middrides/subscription","commits_url":"https://api.github.com/repos/woojinrichardson/middrides/commits{/sha}","git_commits_url":"https://api.github.com/repos/woojinrichardson/middrides/git/commits{/sha}","comments_url":"https://api.github.com/repos/woojinrichardson/middrides/comments{/number}","issue_comment_url":"https://api.github.com/repos/woojinrichardson/middrides/issues/comments{/number}","contents_url":"https://api.github.com/repos/woojinrichardson/middrides/contents/{+path}","compare_url":"https://api.github.com/repos/woojinrichardson/middrides/compare/{base}...{head}","merges_url":"https://api.github.com/repos/woojinrichardson/middrides/merges","archive_url":"https://api.github.com/repos/woojinrichardson/middrides/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/woojinrichardson/middrides/downloads","issues_url":"https://api.github.com/repos/woojinrichardson/middrides/issues{/number}","pulls_url":"https://api.github.com/repos/woojinrichardson/middrides/pulls{/number}","milestones_url":"https://api.github.com/repos/woojinrichardson/middrides/milestones{/number}","notifications_url":"https://api.github.com/repos/woojinrichardson/middrides/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/woojinrichardson/middrides/labels{/name}","releases_url":"https://api.github.com/repos/woojinrichardson/middrides/releases{/id}","deployments_url":"https://api.github.com/repos/woojinrichardson/middrides/deployments","created_at":"2018-11-02T20:44:25Z","updated_at":"2018-11-02T21:33:47Z","pushed_at":"2018-11-06T02:10:11Z","git_url":"git://github.com/woojinrichardson/middrides.git","ssh_url":"git@github.com:woojinrichardson/middrides.git","clone_url":"https://github.com/woojinrichardson/middrides.git","svn_url":"https://github.com/woojinrichardson/middrides","homepage":null,"size":14453,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":1,"license":null,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/woojinrichardson/middrides/pulls/1"},"html":{"href":"https://github.com/woojinrichardson/middrides/pull/1"},"issue":{"href":"https://api.github.com/repos/woojinrichardson/middrides/issues/1"},"comments":{"href":"https://api.github.com/repos/woojinrichardson/middrides/issues/1/comments"},"review_comments":{"href":"https://api.github.com/repos/woojinrichardson/middrides/pulls/1/comments"},"review_comment":{"href":"https://api.github.com/repos/woojinrichardson/middrides/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/woojinrichardson/middrides/pulls/1/commits"},"statuses":{"href":"https://api.github.com/repos/woojinrichardson/middrides/statuses/b694aae5d78198ff2e25c96b95e8d6d0497761dc"}},"author_association":"OWNER"}}
{"actor":{"display_login":"sunyang713"}}