{"action":"created","comment":{"url":"https://api.github.com/repos/teamagam/GGMessaging/pulls/comments/65004576","id":65004576,"diff_hunk":"@@ -28,6 +28,16 @@ module.exports = router;\n router.post(\"/\", upload.single('image'), function (httpRequest, httpResponse, next) {\n     var file = httpRequest.file;\n \n+    //JSON validation\n+    var msg = JSON.parse(httpRequest.body.message);\n+    var error = common.validateMessage(msg);\n+    if(error){\n+        //Bad Request\n+        error.status = 400;\n+        console.log(error);","path":"routes/images.js","position":10,"original_position":10,"commit_id":"80dccaa5825877aed9290196947598d52c25edda","original_commit_id":"80dccaa5825877aed9290196947598d52c25edda","user":{"login":"teamagam3","id":18391871,"avatar_url":"https://avatars.githubusercontent.com/u/18391871?v=3","gravatar_id":"","url":"https://api.github.com/users/teamagam3","html_url":"https://github.com/teamagam3","followers_url":"https://api.github.com/users/teamagam3/followers","following_url":"https://api.github.com/users/teamagam3/following{/other_user}","gists_url":"https://api.github.com/users/teamagam3/gists{/gist_id}","starred_url":"https://api.github.com/users/teamagam3/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/teamagam3/subscriptions","organizations_url":"https://api.github.com/users/teamagam3/orgs","repos_url":"https://api.github.com/users/teamagam3/repos","events_url":"https://api.github.com/users/teamagam3/events{/privacy}","received_events_url":"https://api.github.com/users/teamagam3/received_events","type":"User","site_admin":false},"body":"Use console.error for that !fix","created_at":"2016-05-29T13:20:03Z","updated_at":"2016-05-29T13:20:03Z","html_url":"https://github.com/teamagam/GGMessaging/pull/6#discussion_r65004576","pull_request_url":"https://api.github.com/repos/teamagam/GGMessaging/pulls/6","_links":{"self":{"href":"https://api.github.com/repos/teamagam/GGMessaging/pulls/comments/65004576"},"html":{"href":"https://github.com/teamagam/GGMessaging/pull/6#discussion_r65004576"},"pull_request":{"href":"https://api.github.com/repos/teamagam/GGMessaging/pulls/6"}}},"pull_request":{"url":"https://api.github.com/repos/teamagam/GGMessaging/pulls/6","id":71825804,"html_url":"https://github.com/teamagam/GGMessaging/pull/6","diff_url":"https://github.com/teamagam/GGMessaging/pull/6.diff","patch_url":"https://github.com/teamagam/GGMessaging/pull/6.patch","issue_url":"https://api.github.com/repos/teamagam/GGMessaging/issues/6","number":6,"state":"open","locked":false,"title":"added validation of json of message value.","user":{"login":"teamagam1","id":17426610,"avatar_url":"https://avatars.githubusercontent.com/u/17426610?v=3","gravatar_id":"","url":"https://api.github.com/users/teamagam1","html_url":"https://github.com/teamagam1","followers_url":"https://api.github.com/users/teamagam1/followers","following_url":"https://api.github.com/users/teamagam1/following{/other_user}","gists_url":"https://api.github.com/users/teamagam1/gists{/gist_id}","starred_url":"https://api.github.com/users/teamagam1/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/teamagam1/subscriptions","organizations_url":"https://api.github.com/users/teamagam1/orgs","repos_url":"https://api.github.com/users/teamagam1/repos","events_url":"https://api.github.com/users/teamagam1/events{/privacy}","received_events_url":"https://api.github.com/users/teamagam1/received_events","type":"User","site_admin":false},"body":"added validation of json of message value.","created_at":"2016-05-29T12:15:58Z","updated_at":"2016-05-29T13:20:03Z","closed_at":null,"merged_at":null,"merge_commit_sha":"ea134b02f89764ab644dad44293c3ce351bb39d0","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/teamagam/GGMessaging/pulls/6/commits","review_comments_url":"https://api.github.com/repos/teamagam/GGMessaging/pulls/6/comments","review_comment_url":"https://api.github.com/repos/teamagam/GGMessaging/pulls/comments{/number}","comments_url":"https://api.github.com/repos/teamagam/GGMessaging/issues/6/comments","statuses_url":"https://api.github.com/repos/teamagam/GGMessaging/statuses/80dccaa5825877aed9290196947598d52c25edda","head":{"label":"teamagam:feature/upload_images_proxy","ref":"feature/upload_images_proxy","sha":"80dccaa5825877aed9290196947598d52c25edda","user":{"login":"teamagam","id":16633359,"avatar_url":"https://avatars.githubusercontent.com/u/16633359?v=3","gravatar_id":"","url":"https://api.github.com/users/teamagam","html_url":"https://github.com/teamagam","followers_url":"https://api.github.com/users/teamagam/followers","following_url":"https://api.github.com/users/teamagam/following{/other_user}","gists_url":"https://api.github.com/users/teamagam/gists{/gist_id}","starred_url":"https://api.github.com/users/teamagam/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/teamagam/subscriptions","organizations_url":"https://api.github.com/users/teamagam/orgs","repos_url":"https://api.github.com/users/teamagam/repos","events_url":"https://api.github.com/users/teamagam/events{/privacy}","received_events_url":"https://api.github.com/users/teamagam/received_events","type":"Organization","site_admin":false},"repo":{"id":54319889,"name":"GGMessaging","full_name":"teamagam/GGMessaging","owner":{"login":"teamagam","id":16633359,"avatar_url":"https://avatars.githubusercontent.com/u/16633359?v=3","gravatar_id":"","url":"https://api.github.com/users/teamagam","html_url":"https://github.com/teamagam","followers_url":"https://api.github.com/users/teamagam/followers","following_url":"https://api.github.com/users/teamagam/following{/other_user}","gists_url":"https://api.github.com/users/teamagam/gists{/gist_id}","starred_url":"https://api.github.com/users/teamagam/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/teamagam/subscriptions","organizations_url":"https://api.github.com/users/teamagam/orgs","repos_url":"https://api.github.com/users/teamagam/repos","events_url":"https://api.github.com/users/teamagam/events{/privacy}","received_events_url":"https://api.github.com/users/teamagam/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/teamagam/GGMessaging","description":"","fork":false,"url":"https://api.github.com/repos/teamagam/GGMessaging","forks_url":"https://api.github.com/repos/teamagam/GGMessaging/forks","keys_url":"https://api.github.com/repos/teamagam/GGMessaging/keys{/key_id}","collaborators_url":"https://api.github.com/repos/teamagam/GGMessaging/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/teamagam/GGMessaging/teams","hooks_url":"https://api.github.com/repos/teamagam/GGMessaging/hooks","issue_events_url":"https://api.github.com/repos/teamagam/GGMessaging/issues/events{/number}","events_url":"https://api.github.com/repos/teamagam/GGMessaging/events","assignees_url":"https://api.github.com/repos/teamagam/GGMessaging/assignees{/user}","branches_url":"https://api.github.com/repos/teamagam/GGMessaging/branches{/branch}","tags_url":"https://api.github.com/repos/teamagam/GGMessaging/tags","blobs_url":"https://api.github.com/repos/teamagam/GGMessaging/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/teamagam/GGMessaging/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/teamagam/GGMessaging/git/refs{/sha}","trees_url":"https://api.github.com/repos/teamagam/GGMessaging/git/trees{/sha}","statuses_url":"https://api.github.com/repos/teamagam/GGMessaging/statuses/{sha}","languages_url":"https://api.github.com/repos/teamagam/GGMessaging/languages","stargazers_url":"https://api.github.com/repos/teamagam/GGMessaging/stargazers","contributors_url":"https://api.github.com/repos/teamagam/GGMessaging/contributors","subscribers_url":"https://api.github.com/repos/teamagam/GGMessaging/subscribers","subscription_url":"https://api.github.com/repos/teamagam/GGMessaging/subscription","commits_url":"https://api.github.com/repos/teamagam/GGMessaging/commits{/sha}","git_commits_url":"https://api.github.com/repos/teamagam/GGMessaging/git/commits{/sha}","comments_url":"https://api.github.com/repos/teamagam/GGMessaging/comments{/number}","issue_comment_url":"https://api.github.com/repos/teamagam/GGMessaging/issues/comments{/number}","contents_url":"https://api.github.com/repos/teamagam/GGMessaging/contents/{+path}","compare_url":"https://api.github.com/repos/teamagam/GGMessaging/compare/{base}...{head}","merges_url":"https://api.github.com/repos/teamagam/GGMessaging/merges","archive_url":"https://api.github.com/repos/teamagam/GGMessaging/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/teamagam/GGMessaging/downloads","issues_url":"https://api.github.com/repos/teamagam/GGMessaging/issues{/number}","pulls_url":"https://api.github.com/repos/teamagam/GGMessaging/pulls{/number}","milestones_url":"https://api.github.com/repos/teamagam/GGMessaging/milestones{/number}","notifications_url":"https://api.github.com/repos/teamagam/GGMessaging/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/teamagam/GGMessaging/labels{/name}","releases_url":"https://api.github.com/repos/teamagam/GGMessaging/releases{/id}","deployments_url":"https://api.github.com/repos/teamagam/GGMessaging/deployments","created_at":"2016-03-20T13:47:18Z","updated_at":"2016-05-01T09:20:31Z","pushed_at":"2016-05-29T12:15:59Z","git_url":"git://github.com/teamagam/GGMessaging.git","ssh_url":"git@github.com:teamagam/GGMessaging.git","clone_url":"https://github.com/teamagam/GGMessaging.git","svn_url":"https://github.com/teamagam/GGMessaging","homepage":null,"size":25,"stargazers_count":1,"watchers_count":1,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":1,"forks":1,"open_issues":1,"watchers":1,"default_branch":"master"}},"base":{"label":"teamagam:develop","ref":"develop","sha":"c90576763104090672a19ebda3cefac9e9c5b118","user":{"login":"teamagam","id":16633359,"avatar_url":"https://avatars.githubusercontent.com/u/16633359?v=3","gravatar_id":"","url":"https://api.github.com/users/teamagam","html_url":"https://github.com/teamagam","followers_url":"https://api.github.com/users/teamagam/followers","following_url":"https://api.github.com/users/teamagam/following{/other_user}","gists_url":"https://api.github.com/users/teamagam/gists{/gist_id}","starred_url":"https://api.github.com/users/teamagam/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/teamagam/subscriptions","organizations_url":"https://api.github.com/users/teamagam/orgs","repos_url":"https://api.github.com/users/teamagam/repos","events_url":"https://api.github.com/users/teamagam/events{/privacy}","received_events_url":"https://api.github.com/users/teamagam/received_events","type":"Organization","site_admin":false},"repo":{"id":54319889,"name":"GGMessaging","full_name":"teamagam/GGMessaging","owner":{"login":"teamagam","id":16633359,"avatar_url":"https://avatars.githubusercontent.com/u/16633359?v=3","gravatar_id":"","url":"https://api.github.com/users/teamagam","html_url":"https://github.com/teamagam","followers_url":"https://api.github.com/users/teamagam/followers","following_url":"https://api.github.com/users/teamagam/following{/other_user}","gists_url":"https://api.github.com/users/teamagam/gists{/gist_id}","starred_url":"https://api.github.com/users/teamagam/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/teamagam/subscriptions","organizations_url":"https://api.github.com/users/teamagam/orgs","repos_url":"https://api.github.com/users/teamagam/repos","events_url":"https://api.github.com/users/teamagam/events{/privacy}","received_events_url":"https://api.github.com/users/teamagam/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/teamagam/GGMessaging","description":"","fork":false,"url":"https://api.github.com/repos/teamagam/GGMessaging","forks_url":"https://api.github.com/repos/teamagam/GGMessaging/forks","keys_url":"https://api.github.com/repos/teamagam/GGMessaging/keys{/key_id}","collaborators_url":"https://api.github.com/repos/teamagam/GGMessaging/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/teamagam/GGMessaging/teams","hooks_url":"https://api.github.com/repos/teamagam/GGMessaging/hooks","issue_events_url":"https://api.github.com/repos/teamagam/GGMessaging/issues/events{/number}","events_url":"https://api.github.com/repos/teamagam/GGMessaging/events","assignees_url":"https://api.github.com/repos/teamagam/GGMessaging/assignees{/user}","branches_url":"https://api.github.com/repos/teamagam/GGMessaging/branches{/branch}","tags_url":"https://api.github.com/repos/teamagam/GGMessaging/tags","blobs_url":"https://api.github.com/repos/teamagam/GGMessaging/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/teamagam/GGMessaging/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/teamagam/GGMessaging/git/refs{/sha}","trees_url":"https://api.github.com/repos/teamagam/GGMessaging/git/trees{/sha}","statuses_url":"https://api.github.com/repos/teamagam/GGMessaging/statuses/{sha}","languages_url":"https://api.github.com/repos/teamagam/GGMessaging/languages","stargazers_url":"https://api.github.com/repos/teamagam/GGMessaging/stargazers","contributors_url":"https://api.github.com/repos/teamagam/GGMessaging/contributors","subscribers_url":"https://api.github.com/repos/teamagam/GGMessaging/subscribers","subscription_url":"https://api.github.com/repos/teamagam/GGMessaging/subscription","commits_url":"https://api.github.com/repos/teamagam/GGMessaging/commits{/sha}","git_commits_url":"https://api.github.com/repos/teamagam/GGMessaging/git/commits{/sha}","comments_url":"https://api.github.com/repos/teamagam/GGMessaging/comments{/number}","issue_comment_url":"https://api.github.com/repos/teamagam/GGMessaging/issues/comments{/number}","contents_url":"https://api.github.com/repos/teamagam/GGMessaging/contents/{+path}","compare_url":"https://api.github.com/repos/teamagam/GGMessaging/compare/{base}...{head}","merges_url":"https://api.github.com/repos/teamagam/GGMessaging/merges","archive_url":"https://api.github.com/repos/teamagam/GGMessaging/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/teamagam/GGMessaging/downloads","issues_url":"https://api.github.com/repos/teamagam/GGMessaging/issues{/number}","pulls_url":"https://api.github.com/repos/teamagam/GGMessaging/pulls{/number}","milestones_url":"https://api.github.com/repos/teamagam/GGMessaging/milestones{/number}","notifications_url":"https://api.github.com/repos/teamagam/GGMessaging/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/teamagam/GGMessaging/labels{/name}","releases_url":"https://api.github.com/repos/teamagam/GGMessaging/releases{/id}","deployments_url":"https://api.github.com/repos/teamagam/GGMessaging/deployments","created_at":"2016-03-20T13:47:18Z","updated_at":"2016-05-01T09:20:31Z","pushed_at":"2016-05-29T12:15:59Z","git_url":"git://github.com/teamagam/GGMessaging.git","ssh_url":"git@github.com:teamagam/GGMessaging.git","clone_url":"https://github.com/teamagam/GGMessaging.git","svn_url":"https://github.com/teamagam/GGMessaging","homepage":null,"size":25,"stargazers_count":1,"watchers_count":1,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":1,"forks":1,"open_issues":1,"watchers":1,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/teamagam/GGMessaging/pulls/6"},"html":{"href":"https://github.com/teamagam/GGMessaging/pull/6"},"issue":{"href":"https://api.github.com/repos/teamagam/GGMessaging/issues/6"},"comments":{"href":"https://api.github.com/repos/teamagam/GGMessaging/issues/6/comments"},"review_comments":{"href":"https://api.github.com/repos/teamagam/GGMessaging/pulls/6/comments"},"review_comment":{"href":"https://api.github.com/repos/teamagam/GGMessaging/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/teamagam/GGMessaging/pulls/6/commits"},"statuses":{"href":"https://api.github.com/repos/teamagam/GGMessaging/statuses/80dccaa5825877aed9290196947598d52c25edda"}}}}
{"actor":{"display_login":"teamagam3"}}