{"action":"created","comment":{"url":"https://api.github.com/repos/knorcika/task-manager/pulls/comments/87099659","pull_request_review_id":7725690,"id":87099659,"diff_hunk":"@@ -52,6 +56,37 @@ module.exports = {\n       }\n       return res.send('success');\n     });\n+  },\n+\n+\n+  assign: function (req, res) {\n+\n+    var taskId = req.params.taskId;\n+    var arrAssign = req.body.assigned;\n+\n+    async.each(\n+      arrAssign, //items,\n+\n+      function (item, callback) {\n+        Task.update({_id: ObjectId(taskId)}, {$addToSet: {assigned: item}}, function (err, tasks) {\n+          if (!!err) {\n+            return res.send(err);\n+          }\n+          Task.populate(tasks, {path: 'assigned'});\n+          //return res.send(tasks);\n+        });\n+\n+        callback();","path":"api/controllers/task.js","position":49,"original_position":49,"commit_id":"30941c8cc69f21edf5d3378e1eab60437173b557","original_commit_id":"30941c8cc69f21edf5d3378e1eab60437173b557","user":{"login":"knorcika","id":10308395,"avatar_url":"https://avatars.githubusercontent.com/u/10308395?v=3","gravatar_id":"","url":"https://api.github.com/users/knorcika","html_url":"https://github.com/knorcika","followers_url":"https://api.github.com/users/knorcika/followers","following_url":"https://api.github.com/users/knorcika/following{/other_user}","gists_url":"https://api.github.com/users/knorcika/gists{/gist_id}","starred_url":"https://api.github.com/users/knorcika/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/knorcika/subscriptions","organizations_url":"https://api.github.com/users/knorcika/orgs","repos_url":"https://api.github.com/users/knorcika/repos","events_url":"https://api.github.com/users/knorcika/events{/privacy}","received_events_url":"https://api.github.com/users/knorcika/received_events","type":"User","site_admin":false},"body":"Remove this line.","created_at":"2016-11-08T22:34:56Z","updated_at":"2016-11-08T22:52:05Z","html_url":"https://github.com/knorcika/task-manager/pull/4#discussion_r87099659","pull_request_url":"https://api.github.com/repos/knorcika/task-manager/pulls/4","_links":{"self":{"href":"https://api.github.com/repos/knorcika/task-manager/pulls/comments/87099659"},"html":{"href":"https://github.com/knorcika/task-manager/pull/4#discussion_r87099659"},"pull_request":{"href":"https://api.github.com/repos/knorcika/task-manager/pulls/4"}}},"pull_request":{"url":"https://api.github.com/repos/knorcika/task-manager/pulls/4","id":92872250,"html_url":"https://github.com/knorcika/task-manager/pull/4","diff_url":"https://github.com/knorcika/task-manager/pull/4.diff","patch_url":"https://github.com/knorcika/task-manager/pull/4.patch","issue_url":"https://api.github.com/repos/knorcika/task-manager/issues/4","number":4,"state":"open","locked":false,"title":"[WIP] Feature/tm 9","user":{"login":"knorcika","id":10308395,"avatar_url":"https://avatars.githubusercontent.com/u/10308395?v=3","gravatar_id":"","url":"https://api.github.com/users/knorcika","html_url":"https://github.com/knorcika","followers_url":"https://api.github.com/users/knorcika/followers","following_url":"https://api.github.com/users/knorcika/following{/other_user}","gists_url":"https://api.github.com/users/knorcika/gists{/gist_id}","starred_url":"https://api.github.com/users/knorcika/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/knorcika/subscriptions","organizations_url":"https://api.github.com/users/knorcika/orgs","repos_url":"https://api.github.com/users/knorcika/repos","events_url":"https://api.github.com/users/knorcika/events{/privacy}","received_events_url":"https://api.github.com/users/knorcika/received_events","type":"User","site_admin":false},"body":"","created_at":"2016-11-08T22:28:50Z","updated_at":"2016-11-08T22:52:05Z","closed_at":null,"merged_at":null,"merge_commit_sha":"d104dced64277ad0977f87c0bd4ee6e98949a7e0","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/knorcika/task-manager/pulls/4/commits","review_comments_url":"https://api.github.com/repos/knorcika/task-manager/pulls/4/comments","review_comment_url":"https://api.github.com/repos/knorcika/task-manager/pulls/comments{/number}","comments_url":"https://api.github.com/repos/knorcika/task-manager/issues/4/comments","statuses_url":"https://api.github.com/repos/knorcika/task-manager/statuses/30941c8cc69f21edf5d3378e1eab60437173b557","head":{"label":"knorcika:feature/TM-9","ref":"feature/TM-9","sha":"30941c8cc69f21edf5d3378e1eab60437173b557","user":{"login":"knorcika","id":10308395,"avatar_url":"https://avatars.githubusercontent.com/u/10308395?v=3","gravatar_id":"","url":"https://api.github.com/users/knorcika","html_url":"https://github.com/knorcika","followers_url":"https://api.github.com/users/knorcika/followers","following_url":"https://api.github.com/users/knorcika/following{/other_user}","gists_url":"https://api.github.com/users/knorcika/gists{/gist_id}","starred_url":"https://api.github.com/users/knorcika/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/knorcika/subscriptions","organizations_url":"https://api.github.com/users/knorcika/orgs","repos_url":"https://api.github.com/users/knorcika/repos","events_url":"https://api.github.com/users/knorcika/events{/privacy}","received_events_url":"https://api.github.com/users/knorcika/received_events","type":"User","site_admin":false},"repo":{"id":70835227,"name":"task-manager","full_name":"knorcika/task-manager","owner":{"login":"knorcika","id":10308395,"avatar_url":"https://avatars.githubusercontent.com/u/10308395?v=3","gravatar_id":"","url":"https://api.github.com/users/knorcika","html_url":"https://github.com/knorcika","followers_url":"https://api.github.com/users/knorcika/followers","following_url":"https://api.github.com/users/knorcika/following{/other_user}","gists_url":"https://api.github.com/users/knorcika/gists{/gist_id}","starred_url":"https://api.github.com/users/knorcika/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/knorcika/subscriptions","organizations_url":"https://api.github.com/users/knorcika/orgs","repos_url":"https://api.github.com/users/knorcika/repos","events_url":"https://api.github.com/users/knorcika/events{/privacy}","received_events_url":"https://api.github.com/users/knorcika/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/knorcika/task-manager","description":null,"fork":true,"url":"https://api.github.com/repos/knorcika/task-manager","forks_url":"https://api.github.com/repos/knorcika/task-manager/forks","keys_url":"https://api.github.com/repos/knorcika/task-manager/keys{/key_id}","collaborators_url":"https://api.github.com/repos/knorcika/task-manager/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/knorcika/task-manager/teams","hooks_url":"https://api.github.com/repos/knorcika/task-manager/hooks","issue_events_url":"https://api.github.com/repos/knorcika/task-manager/issues/events{/number}","events_url":"https://api.github.com/repos/knorcika/task-manager/events","assignees_url":"https://api.github.com/repos/knorcika/task-manager/assignees{/user}","branches_url":"https://api.github.com/repos/knorcika/task-manager/branches{/branch}","tags_url":"https://api.github.com/repos/knorcika/task-manager/tags","blobs_url":"https://api.github.com/repos/knorcika/task-manager/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/knorcika/task-manager/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/knorcika/task-manager/git/refs{/sha}","trees_url":"https://api.github.com/repos/knorcika/task-manager/git/trees{/sha}","statuses_url":"https://api.github.com/repos/knorcika/task-manager/statuses/{sha}","languages_url":"https://api.github.com/repos/knorcika/task-manager/languages","stargazers_url":"https://api.github.com/repos/knorcika/task-manager/stargazers","contributors_url":"https://api.github.com/repos/knorcika/task-manager/contributors","subscribers_url":"https://api.github.com/repos/knorcika/task-manager/subscribers","subscription_url":"https://api.github.com/repos/knorcika/task-manager/subscription","commits_url":"https://api.github.com/repos/knorcika/task-manager/commits{/sha}","git_commits_url":"https://api.github.com/repos/knorcika/task-manager/git/commits{/sha}","comments_url":"https://api.github.com/repos/knorcika/task-manager/comments{/number}","issue_comment_url":"https://api.github.com/repos/knorcika/task-manager/issues/comments{/number}","contents_url":"https://api.github.com/repos/knorcika/task-manager/contents/{+path}","compare_url":"https://api.github.com/repos/knorcika/task-manager/compare/{base}...{head}","merges_url":"https://api.github.com/repos/knorcika/task-manager/merges","archive_url":"https://api.github.com/repos/knorcika/task-manager/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/knorcika/task-manager/downloads","issues_url":"https://api.github.com/repos/knorcika/task-manager/issues{/number}","pulls_url":"https://api.github.com/repos/knorcika/task-manager/pulls{/number}","milestones_url":"https://api.github.com/repos/knorcika/task-manager/milestones{/number}","notifications_url":"https://api.github.com/repos/knorcika/task-manager/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/knorcika/task-manager/labels{/name}","releases_url":"https://api.github.com/repos/knorcika/task-manager/releases{/id}","deployments_url":"https://api.github.com/repos/knorcika/task-manager/deployments","created_at":"2016-10-13T18:18:28Z","updated_at":"2016-10-13T18:18:29Z","pushed_at":"2016-11-08T22:28:51Z","git_url":"git://github.com/knorcika/task-manager.git","ssh_url":"git@github.com:knorcika/task-manager.git","clone_url":"https://github.com/knorcika/task-manager.git","svn_url":"https://github.com/knorcika/task-manager","homepage":null,"size":28,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"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":"develop"}},"base":{"label":"knorcika:develop","ref":"develop","sha":"7867581064718881e3f275e03628d43e217db9f7","user":{"login":"knorcika","id":10308395,"avatar_url":"https://avatars.githubusercontent.com/u/10308395?v=3","gravatar_id":"","url":"https://api.github.com/users/knorcika","html_url":"https://github.com/knorcika","followers_url":"https://api.github.com/users/knorcika/followers","following_url":"https://api.github.com/users/knorcika/following{/other_user}","gists_url":"https://api.github.com/users/knorcika/gists{/gist_id}","starred_url":"https://api.github.com/users/knorcika/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/knorcika/subscriptions","organizations_url":"https://api.github.com/users/knorcika/orgs","repos_url":"https://api.github.com/users/knorcika/repos","events_url":"https://api.github.com/users/knorcika/events{/privacy}","received_events_url":"https://api.github.com/users/knorcika/received_events","type":"User","site_admin":false},"repo":{"id":70835227,"name":"task-manager","full_name":"knorcika/task-manager","owner":{"login":"knorcika","id":10308395,"avatar_url":"https://avatars.githubusercontent.com/u/10308395?v=3","gravatar_id":"","url":"https://api.github.com/users/knorcika","html_url":"https://github.com/knorcika","followers_url":"https://api.github.com/users/knorcika/followers","following_url":"https://api.github.com/users/knorcika/following{/other_user}","gists_url":"https://api.github.com/users/knorcika/gists{/gist_id}","starred_url":"https://api.github.com/users/knorcika/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/knorcika/subscriptions","organizations_url":"https://api.github.com/users/knorcika/orgs","repos_url":"https://api.github.com/users/knorcika/repos","events_url":"https://api.github.com/users/knorcika/events{/privacy}","received_events_url":"https://api.github.com/users/knorcika/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/knorcika/task-manager","description":null,"fork":true,"url":"https://api.github.com/repos/knorcika/task-manager","forks_url":"https://api.github.com/repos/knorcika/task-manager/forks","keys_url":"https://api.github.com/repos/knorcika/task-manager/keys{/key_id}","collaborators_url":"https://api.github.com/repos/knorcika/task-manager/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/knorcika/task-manager/teams","hooks_url":"https://api.github.com/repos/knorcika/task-manager/hooks","issue_events_url":"https://api.github.com/repos/knorcika/task-manager/issues/events{/number}","events_url":"https://api.github.com/repos/knorcika/task-manager/events","assignees_url":"https://api.github.com/repos/knorcika/task-manager/assignees{/user}","branches_url":"https://api.github.com/repos/knorcika/task-manager/branches{/branch}","tags_url":"https://api.github.com/repos/knorcika/task-manager/tags","blobs_url":"https://api.github.com/repos/knorcika/task-manager/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/knorcika/task-manager/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/knorcika/task-manager/git/refs{/sha}","trees_url":"https://api.github.com/repos/knorcika/task-manager/git/trees{/sha}","statuses_url":"https://api.github.com/repos/knorcika/task-manager/statuses/{sha}","languages_url":"https://api.github.com/repos/knorcika/task-manager/languages","stargazers_url":"https://api.github.com/repos/knorcika/task-manager/stargazers","contributors_url":"https://api.github.com/repos/knorcika/task-manager/contributors","subscribers_url":"https://api.github.com/repos/knorcika/task-manager/subscribers","subscription_url":"https://api.github.com/repos/knorcika/task-manager/subscription","commits_url":"https://api.github.com/repos/knorcika/task-manager/commits{/sha}","git_commits_url":"https://api.github.com/repos/knorcika/task-manager/git/commits{/sha}","comments_url":"https://api.github.com/repos/knorcika/task-manager/comments{/number}","issue_comment_url":"https://api.github.com/repos/knorcika/task-manager/issues/comments{/number}","contents_url":"https://api.github.com/repos/knorcika/task-manager/contents/{+path}","compare_url":"https://api.github.com/repos/knorcika/task-manager/compare/{base}...{head}","merges_url":"https://api.github.com/repos/knorcika/task-manager/merges","archive_url":"https://api.github.com/repos/knorcika/task-manager/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/knorcika/task-manager/downloads","issues_url":"https://api.github.com/repos/knorcika/task-manager/issues{/number}","pulls_url":"https://api.github.com/repos/knorcika/task-manager/pulls{/number}","milestones_url":"https://api.github.com/repos/knorcika/task-manager/milestones{/number}","notifications_url":"https://api.github.com/repos/knorcika/task-manager/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/knorcika/task-manager/labels{/name}","releases_url":"https://api.github.com/repos/knorcika/task-manager/releases{/id}","deployments_url":"https://api.github.com/repos/knorcika/task-manager/deployments","created_at":"2016-10-13T18:18:28Z","updated_at":"2016-10-13T18:18:29Z","pushed_at":"2016-11-08T22:28:51Z","git_url":"git://github.com/knorcika/task-manager.git","ssh_url":"git@github.com:knorcika/task-manager.git","clone_url":"https://github.com/knorcika/task-manager.git","svn_url":"https://github.com/knorcika/task-manager","homepage":null,"size":28,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"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":"develop"}},"_links":{"self":{"href":"https://api.github.com/repos/knorcika/task-manager/pulls/4"},"html":{"href":"https://github.com/knorcika/task-manager/pull/4"},"issue":{"href":"https://api.github.com/repos/knorcika/task-manager/issues/4"},"comments":{"href":"https://api.github.com/repos/knorcika/task-manager/issues/4/comments"},"review_comments":{"href":"https://api.github.com/repos/knorcika/task-manager/pulls/4/comments"},"review_comment":{"href":"https://api.github.com/repos/knorcika/task-manager/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/knorcika/task-manager/pulls/4/commits"},"statuses":{"href":"https://api.github.com/repos/knorcika/task-manager/statuses/30941c8cc69f21edf5d3378e1eab60437173b557"}}}}
{"actor":{"display_login":"knorcika"}}