{"action":"created","comment":{"url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/pulls/comments/108129906","pull_request_review_id":29140527,"id":108129906,"diff_hunk":"@@ -0,0 +1,25 @@\n+package seedu.opus.model.comparators;\n+\n+import java.util.Comparator;\n+\n+import seedu.opus.model.task.ReadOnlyTask;\n+\n+public class StartTimeComparator implements Comparator<ReadOnlyTask> {\n+    public int compare(ReadOnlyTask d1, ReadOnlyTask d2) {\n+        boolean hasStartAndEnd = d1.getStartTime().isPresent() && d2.getStartTime().isPresent();\n+        boolean hasStartOrEnd = d1.getStartTime().isPresent() || d2.getStartTime().isPresent();\n+        if (hasStartAndEnd) {\n+            if (d1.getStartTime().get().dateTime.isBefore(d2.getStartTime().get().dateTime)) {\n+                return -1;\n+            } else if (d1.getStartTime().get().dateTime.isAfter(d2.getStartTime().get().dateTime)) {","path":"src/main/java/seedu/opus/model/comparators/StartTimeComparator.java","position":14,"original_position":14,"commit_id":"f1389f856af2811b61b231a5e0b5b50b86c8f535","original_commit_id":"f1389f856af2811b61b231a5e0b5b50b86c8f535","user":{"login":"xbili","id":4846457,"avatar_url":"https://avatars1.githubusercontent.com/u/4846457?v=3","gravatar_id":"","url":"https://api.github.com/users/xbili","html_url":"https://github.com/xbili","followers_url":"https://api.github.com/users/xbili/followers","following_url":"https://api.github.com/users/xbili/following{/other_user}","gists_url":"https://api.github.com/users/xbili/gists{/gist_id}","starred_url":"https://api.github.com/users/xbili/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/xbili/subscriptions","organizations_url":"https://api.github.com/users/xbili/orgs","repos_url":"https://api.github.com/users/xbili/repos","events_url":"https://api.github.com/users/xbili/events{/privacy}","received_events_url":"https://api.github.com/users/xbili/received_events","type":"User","site_admin":false},"body":"Same here.","created_at":"2017-03-27T09:48:51Z","updated_at":"2017-03-27T09:52:43Z","html_url":"https://github.com/CS2103JAN2017-W15-B3/main/pull/179#discussion_r108129906","pull_request_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/pulls/179","_links":{"self":{"href":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/pulls/comments/108129906"},"html":{"href":"https://github.com/CS2103JAN2017-W15-B3/main/pull/179#discussion_r108129906"},"pull_request":{"href":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/pulls/179"}}},"pull_request":{"url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/pulls/179","id":112628780,"html_url":"https://github.com/CS2103JAN2017-W15-B3/main/pull/179","diff_url":"https://github.com/CS2103JAN2017-W15-B3/main/pull/179.diff","patch_url":"https://github.com/CS2103JAN2017-W15-B3/main/pull/179.patch","issue_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/issues/179","number":179,"state":"open","locked":false,"title":"Sort command","user":{"login":"gjlam95","id":19379517,"avatar_url":"https://avatars2.githubusercontent.com/u/19379517?v=3","gravatar_id":"","url":"https://api.github.com/users/gjlam95","html_url":"https://github.com/gjlam95","followers_url":"https://api.github.com/users/gjlam95/followers","following_url":"https://api.github.com/users/gjlam95/following{/other_user}","gists_url":"https://api.github.com/users/gjlam95/gists{/gist_id}","starred_url":"https://api.github.com/users/gjlam95/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gjlam95/subscriptions","organizations_url":"https://api.github.com/users/gjlam95/orgs","repos_url":"https://api.github.com/users/gjlam95/repos","events_url":"https://api.github.com/users/gjlam95/events{/privacy}","received_events_url":"https://api.github.com/users/gjlam95/received_events","type":"User","site_admin":false},"body":"","created_at":"2017-03-26T14:11:29Z","updated_at":"2017-03-27T09:52:43Z","closed_at":null,"merged_at":null,"merge_commit_sha":"414b0fc95bcb2f7cbc4c56bd5a5b56b09d162c30","assignee":{"login":"gjlam95","id":19379517,"avatar_url":"https://avatars2.githubusercontent.com/u/19379517?v=3","gravatar_id":"","url":"https://api.github.com/users/gjlam95","html_url":"https://github.com/gjlam95","followers_url":"https://api.github.com/users/gjlam95/followers","following_url":"https://api.github.com/users/gjlam95/following{/other_user}","gists_url":"https://api.github.com/users/gjlam95/gists{/gist_id}","starred_url":"https://api.github.com/users/gjlam95/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gjlam95/subscriptions","organizations_url":"https://api.github.com/users/gjlam95/orgs","repos_url":"https://api.github.com/users/gjlam95/repos","events_url":"https://api.github.com/users/gjlam95/events{/privacy}","received_events_url":"https://api.github.com/users/gjlam95/received_events","type":"User","site_admin":false},"assignees":[{"login":"gjlam95","id":19379517,"avatar_url":"https://avatars2.githubusercontent.com/u/19379517?v=3","gravatar_id":"","url":"https://api.github.com/users/gjlam95","html_url":"https://github.com/gjlam95","followers_url":"https://api.github.com/users/gjlam95/followers","following_url":"https://api.github.com/users/gjlam95/following{/other_user}","gists_url":"https://api.github.com/users/gjlam95/gists{/gist_id}","starred_url":"https://api.github.com/users/gjlam95/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gjlam95/subscriptions","organizations_url":"https://api.github.com/users/gjlam95/orgs","repos_url":"https://api.github.com/users/gjlam95/repos","events_url":"https://api.github.com/users/gjlam95/events{/privacy}","received_events_url":"https://api.github.com/users/gjlam95/received_events","type":"User","site_admin":false}],"milestone":{"url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/milestones/5","html_url":"https://github.com/CS2103JAN2017-W15-B3/main/milestone/5","labels_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/milestones/5/labels","id":2355315,"number":5,"title":"v0.4","description":"","creator":{"login":"mynameisyz","id":22652013,"avatar_url":"https://avatars1.githubusercontent.com/u/22652013?v=3","gravatar_id":"","url":"https://api.github.com/users/mynameisyz","html_url":"https://github.com/mynameisyz","followers_url":"https://api.github.com/users/mynameisyz/followers","following_url":"https://api.github.com/users/mynameisyz/following{/other_user}","gists_url":"https://api.github.com/users/mynameisyz/gists{/gist_id}","starred_url":"https://api.github.com/users/mynameisyz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mynameisyz/subscriptions","organizations_url":"https://api.github.com/users/mynameisyz/orgs","repos_url":"https://api.github.com/users/mynameisyz/repos","events_url":"https://api.github.com/users/mynameisyz/events{/privacy}","received_events_url":"https://api.github.com/users/mynameisyz/received_events","type":"User","site_admin":false},"open_issues":8,"closed_issues":27,"state":"open","created_at":"2017-03-01T07:27:45Z","updated_at":"2017-03-27T09:38:24Z","due_on":"2017-03-29T07:00:00Z","closed_at":null},"commits_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/pulls/179/commits","review_comments_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/pulls/179/comments","review_comment_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/pulls/comments{/number}","comments_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/issues/179/comments","statuses_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/statuses/f1389f856af2811b61b231a5e0b5b50b86c8f535","head":{"label":"CS2103JAN2017-W15-B3:sort-command","ref":"sort-command","sha":"f1389f856af2811b61b231a5e0b5b50b86c8f535","user":{"login":"CS2103JAN2017-W15-B3","id":25864757,"avatar_url":"https://avatars3.githubusercontent.com/u/25864757?v=3","gravatar_id":"","url":"https://api.github.com/users/CS2103JAN2017-W15-B3","html_url":"https://github.com/CS2103JAN2017-W15-B3","followers_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/followers","following_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/following{/other_user}","gists_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/gists{/gist_id}","starred_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/subscriptions","organizations_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/orgs","repos_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/repos","events_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/events{/privacy}","received_events_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/received_events","type":"Organization","site_admin":false},"repo":{"id":83023983,"name":"main","full_name":"CS2103JAN2017-W15-B3/main","owner":{"login":"CS2103JAN2017-W15-B3","id":25864757,"avatar_url":"https://avatars3.githubusercontent.com/u/25864757?v=3","gravatar_id":"","url":"https://api.github.com/users/CS2103JAN2017-W15-B3","html_url":"https://github.com/CS2103JAN2017-W15-B3","followers_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/followers","following_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/following{/other_user}","gists_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/gists{/gist_id}","starred_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/subscriptions","organizations_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/orgs","repos_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/repos","events_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/events{/privacy}","received_events_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/CS2103JAN2017-W15-B3/main","description":"Opus: CLI Task Manager 📝","fork":true,"url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main","forks_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/forks","keys_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/keys{/key_id}","collaborators_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/teams","hooks_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/hooks","issue_events_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/issues/events{/number}","events_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/events","assignees_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/assignees{/user}","branches_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/branches{/branch}","tags_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/tags","blobs_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/git/refs{/sha}","trees_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/git/trees{/sha}","statuses_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/statuses/{sha}","languages_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/languages","stargazers_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/stargazers","contributors_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/contributors","subscribers_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/subscribers","subscription_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/subscription","commits_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/commits{/sha}","git_commits_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/git/commits{/sha}","comments_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/comments{/number}","issue_comment_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/issues/comments{/number}","contents_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/contents/{+path}","compare_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/compare/{base}...{head}","merges_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/merges","archive_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/downloads","issues_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/issues{/number}","pulls_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/pulls{/number}","milestones_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/milestones{/number}","notifications_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/labels{/name}","releases_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/releases{/id}","deployments_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/deployments","created_at":"2017-02-24T09:19:31Z","updated_at":"2017-03-24T01:54:52Z","pushed_at":"2017-03-27T09:35:16Z","git_url":"git://github.com/CS2103JAN2017-W15-B3/main.git","ssh_url":"git@github.com:CS2103JAN2017-W15-B3/main.git","clone_url":"https://github.com/CS2103JAN2017-W15-B3/main.git","svn_url":"https://github.com/CS2103JAN2017-W15-B3/main","homepage":"","size":9616,"stargazers_count":2,"watchers_count":2,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":true,"forks_count":1,"mirror_url":null,"open_issues_count":23,"forks":1,"open_issues":23,"watchers":2,"default_branch":"master"}},"base":{"label":"CS2103JAN2017-W15-B3:development","ref":"development","sha":"bcc13f9278397ac6f954ff9e80e5c1cf520a222e","user":{"login":"CS2103JAN2017-W15-B3","id":25864757,"avatar_url":"https://avatars3.githubusercontent.com/u/25864757?v=3","gravatar_id":"","url":"https://api.github.com/users/CS2103JAN2017-W15-B3","html_url":"https://github.com/CS2103JAN2017-W15-B3","followers_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/followers","following_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/following{/other_user}","gists_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/gists{/gist_id}","starred_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/subscriptions","organizations_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/orgs","repos_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/repos","events_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/events{/privacy}","received_events_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/received_events","type":"Organization","site_admin":false},"repo":{"id":83023983,"name":"main","full_name":"CS2103JAN2017-W15-B3/main","owner":{"login":"CS2103JAN2017-W15-B3","id":25864757,"avatar_url":"https://avatars3.githubusercontent.com/u/25864757?v=3","gravatar_id":"","url":"https://api.github.com/users/CS2103JAN2017-W15-B3","html_url":"https://github.com/CS2103JAN2017-W15-B3","followers_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/followers","following_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/following{/other_user}","gists_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/gists{/gist_id}","starred_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/subscriptions","organizations_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/orgs","repos_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/repos","events_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/events{/privacy}","received_events_url":"https://api.github.com/users/CS2103JAN2017-W15-B3/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/CS2103JAN2017-W15-B3/main","description":"Opus: CLI Task Manager 📝","fork":true,"url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main","forks_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/forks","keys_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/keys{/key_id}","collaborators_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/teams","hooks_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/hooks","issue_events_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/issues/events{/number}","events_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/events","assignees_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/assignees{/user}","branches_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/branches{/branch}","tags_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/tags","blobs_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/git/refs{/sha}","trees_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/git/trees{/sha}","statuses_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/statuses/{sha}","languages_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/languages","stargazers_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/stargazers","contributors_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/contributors","subscribers_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/subscribers","subscription_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/subscription","commits_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/commits{/sha}","git_commits_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/git/commits{/sha}","comments_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/comments{/number}","issue_comment_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/issues/comments{/number}","contents_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/contents/{+path}","compare_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/compare/{base}...{head}","merges_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/merges","archive_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/downloads","issues_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/issues{/number}","pulls_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/pulls{/number}","milestones_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/milestones{/number}","notifications_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/labels{/name}","releases_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/releases{/id}","deployments_url":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/deployments","created_at":"2017-02-24T09:19:31Z","updated_at":"2017-03-24T01:54:52Z","pushed_at":"2017-03-27T09:35:16Z","git_url":"git://github.com/CS2103JAN2017-W15-B3/main.git","ssh_url":"git@github.com:CS2103JAN2017-W15-B3/main.git","clone_url":"https://github.com/CS2103JAN2017-W15-B3/main.git","svn_url":"https://github.com/CS2103JAN2017-W15-B3/main","homepage":"","size":9616,"stargazers_count":2,"watchers_count":2,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":true,"forks_count":1,"mirror_url":null,"open_issues_count":23,"forks":1,"open_issues":23,"watchers":2,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/pulls/179"},"html":{"href":"https://github.com/CS2103JAN2017-W15-B3/main/pull/179"},"issue":{"href":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/issues/179"},"comments":{"href":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/issues/179/comments"},"review_comments":{"href":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/pulls/179/comments"},"review_comment":{"href":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/pulls/179/commits"},"statuses":{"href":"https://api.github.com/repos/CS2103JAN2017-W15-B3/main/statuses/f1389f856af2811b61b231a5e0b5b50b86c8f535"}}}}
{"actor":{"display_login":"xbili"}}