{"action":"created","comment":{"url":"https://api.github.com/repos/netguru/bob-the-bot/pulls/comments/212622695","pull_request_review_id":149296590,"id":212622695,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIxMjYyMjY5NQ==","diff_hunk":"@@ -5,24 +5,24 @@ const moment = require('moment');\n const { map } = require('asyncro');\n \n const config = require('../../config/github.config.json');\n+const getOwnerAndRepoName = require('./github.parser');\n \n class HygieneCheckService {\n   constructor(client) {\n     this.client = client;\n   }\n \n-  buildQuery(repositoryName, githubUser) {\n-    return `type:pr+repo:${this.getOwnerRepositoryName(repositoryName)}${this.getPullRequestsScope(githubUser)}`;\n+  buildQuery(repositoryName, githubUser, state = '') {","path":"src/github/HygieneCheck.service.js","position":13,"original_position":13,"commit_id":"988001a6a2705c9ba6ef18bdec6beb046d160c11","original_commit_id":"defd48224709dd9ce5914842e24cf4407cfda816","user":{"login":"Davlis","id":25466166,"node_id":"MDQ6VXNlcjI1NDY2MTY2","avatar_url":"https://avatars3.githubusercontent.com/u/25466166?v=4","gravatar_id":"","url":"https://api.github.com/users/Davlis","html_url":"https://github.com/Davlis","followers_url":"https://api.github.com/users/Davlis/followers","following_url":"https://api.github.com/users/Davlis/following{/other_user}","gists_url":"https://api.github.com/users/Davlis/gists{/gist_id}","starred_url":"https://api.github.com/users/Davlis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Davlis/subscriptions","organizations_url":"https://api.github.com/users/Davlis/orgs","repos_url":"https://api.github.com/users/Davlis/repos","events_url":"https://api.github.com/users/Davlis/events{/privacy}","received_events_url":"https://api.github.com/users/Davlis/received_events","type":"User","site_admin":false},"body":"state here is always `''` right? Because I can't find any execution of buildQuery with third parameter","created_at":"2018-08-24T13:10:38Z","updated_at":"2018-08-24T13:34:50Z","html_url":"https://github.com/netguru/bob-the-bot/pull/31#discussion_r212622695","pull_request_url":"https://api.github.com/repos/netguru/bob-the-bot/pulls/31","author_association":"COLLABORATOR","_links":{"self":{"href":"https://api.github.com/repos/netguru/bob-the-bot/pulls/comments/212622695"},"html":{"href":"https://github.com/netguru/bob-the-bot/pull/31#discussion_r212622695"},"pull_request":{"href":"https://api.github.com/repos/netguru/bob-the-bot/pulls/31"}}},"pull_request":{"url":"https://api.github.com/repos/netguru/bob-the-bot/pulls/31","id":210706369,"node_id":"MDExOlB1bGxSZXF1ZXN0MjEwNzA2MzY5","html_url":"https://github.com/netguru/bob-the-bot/pull/31","diff_url":"https://github.com/netguru/bob-the-bot/pull/31.diff","patch_url":"https://github.com/netguru/bob-the-bot/pull/31.patch","issue_url":"https://api.github.com/repos/netguru/bob-the-bot/issues/31","number":31,"state":"open","locked":false,"title":"Github script: Not removed branches","user":{"login":"krzyurb","id":11517908,"node_id":"MDQ6VXNlcjExNTE3OTA4","avatar_url":"https://avatars3.githubusercontent.com/u/11517908?v=4","gravatar_id":"","url":"https://api.github.com/users/krzyurb","html_url":"https://github.com/krzyurb","followers_url":"https://api.github.com/users/krzyurb/followers","following_url":"https://api.github.com/users/krzyurb/following{/other_user}","gists_url":"https://api.github.com/users/krzyurb/gists{/gist_id}","starred_url":"https://api.github.com/users/krzyurb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/krzyurb/subscriptions","organizations_url":"https://api.github.com/users/krzyurb/orgs","repos_url":"https://api.github.com/users/krzyurb/repos","events_url":"https://api.github.com/users/krzyurb/events{/privacy}","received_events_url":"https://api.github.com/users/krzyurb/received_events","type":"User","site_admin":false},"body":"Command `github hygiene <repository>` shows all merged but not removed branches from repository.\r\n\r\n","created_at":"2018-08-24T10:51:38Z","updated_at":"2018-08-24T13:34:50Z","closed_at":null,"merged_at":null,"merge_commit_sha":"1bc74fe0e29866fdcfc84f3387cc559b57545b0a","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/netguru/bob-the-bot/pulls/31/commits","review_comments_url":"https://api.github.com/repos/netguru/bob-the-bot/pulls/31/comments","review_comment_url":"https://api.github.com/repos/netguru/bob-the-bot/pulls/comments{/number}","comments_url":"https://api.github.com/repos/netguru/bob-the-bot/issues/31/comments","statuses_url":"https://api.github.com/repos/netguru/bob-the-bot/statuses/988001a6a2705c9ba6ef18bdec6beb046d160c11","head":{"label":"netguru:improvement/unclosed-branches","ref":"improvement/unclosed-branches","sha":"988001a6a2705c9ba6ef18bdec6beb046d160c11","user":{"login":"netguru","id":1146,"node_id":"MDEyOk9yZ2FuaXphdGlvbjExNDY=","avatar_url":"https://avatars1.githubusercontent.com/u/1146?v=4","gravatar_id":"","url":"https://api.github.com/users/netguru","html_url":"https://github.com/netguru","followers_url":"https://api.github.com/users/netguru/followers","following_url":"https://api.github.com/users/netguru/following{/other_user}","gists_url":"https://api.github.com/users/netguru/gists{/gist_id}","starred_url":"https://api.github.com/users/netguru/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/netguru/subscriptions","organizations_url":"https://api.github.com/users/netguru/orgs","repos_url":"https://api.github.com/users/netguru/repos","events_url":"https://api.github.com/users/netguru/events{/privacy}","received_events_url":"https://api.github.com/users/netguru/received_events","type":"Organization","site_admin":false},"repo":{"id":141249965,"node_id":"MDEwOlJlcG9zaXRvcnkxNDEyNDk5NjU=","name":"bob-the-bot","full_name":"netguru/bob-the-bot","owner":{"login":"netguru","id":1146,"node_id":"MDEyOk9yZ2FuaXphdGlvbjExNDY=","avatar_url":"https://avatars1.githubusercontent.com/u/1146?v=4","gravatar_id":"","url":"https://api.github.com/users/netguru","html_url":"https://github.com/netguru","followers_url":"https://api.github.com/users/netguru/followers","following_url":"https://api.github.com/users/netguru/following{/other_user}","gists_url":"https://api.github.com/users/netguru/gists{/gist_id}","starred_url":"https://api.github.com/users/netguru/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/netguru/subscriptions","organizations_url":"https://api.github.com/users/netguru/orgs","repos_url":"https://api.github.com/users/netguru/repos","events_url":"https://api.github.com/users/netguru/events{/privacy}","received_events_url":"https://api.github.com/users/netguru/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/netguru/bob-the-bot","description":null,"fork":false,"url":"https://api.github.com/repos/netguru/bob-the-bot","forks_url":"https://api.github.com/repos/netguru/bob-the-bot/forks","keys_url":"https://api.github.com/repos/netguru/bob-the-bot/keys{/key_id}","collaborators_url":"https://api.github.com/repos/netguru/bob-the-bot/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/netguru/bob-the-bot/teams","hooks_url":"https://api.github.com/repos/netguru/bob-the-bot/hooks","issue_events_url":"https://api.github.com/repos/netguru/bob-the-bot/issues/events{/number}","events_url":"https://api.github.com/repos/netguru/bob-the-bot/events","assignees_url":"https://api.github.com/repos/netguru/bob-the-bot/assignees{/user}","branches_url":"https://api.github.com/repos/netguru/bob-the-bot/branches{/branch}","tags_url":"https://api.github.com/repos/netguru/bob-the-bot/tags","blobs_url":"https://api.github.com/repos/netguru/bob-the-bot/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/netguru/bob-the-bot/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/netguru/bob-the-bot/git/refs{/sha}","trees_url":"https://api.github.com/repos/netguru/bob-the-bot/git/trees{/sha}","statuses_url":"https://api.github.com/repos/netguru/bob-the-bot/statuses/{sha}","languages_url":"https://api.github.com/repos/netguru/bob-the-bot/languages","stargazers_url":"https://api.github.com/repos/netguru/bob-the-bot/stargazers","contributors_url":"https://api.github.com/repos/netguru/bob-the-bot/contributors","subscribers_url":"https://api.github.com/repos/netguru/bob-the-bot/subscribers","subscription_url":"https://api.github.com/repos/netguru/bob-the-bot/subscription","commits_url":"https://api.github.com/repos/netguru/bob-the-bot/commits{/sha}","git_commits_url":"https://api.github.com/repos/netguru/bob-the-bot/git/commits{/sha}","comments_url":"https://api.github.com/repos/netguru/bob-the-bot/comments{/number}","issue_comment_url":"https://api.github.com/repos/netguru/bob-the-bot/issues/comments{/number}","contents_url":"https://api.github.com/repos/netguru/bob-the-bot/contents/{+path}","compare_url":"https://api.github.com/repos/netguru/bob-the-bot/compare/{base}...{head}","merges_url":"https://api.github.com/repos/netguru/bob-the-bot/merges","archive_url":"https://api.github.com/repos/netguru/bob-the-bot/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/netguru/bob-the-bot/downloads","issues_url":"https://api.github.com/repos/netguru/bob-the-bot/issues{/number}","pulls_url":"https://api.github.com/repos/netguru/bob-the-bot/pulls{/number}","milestones_url":"https://api.github.com/repos/netguru/bob-the-bot/milestones{/number}","notifications_url":"https://api.github.com/repos/netguru/bob-the-bot/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/netguru/bob-the-bot/labels{/name}","releases_url":"https://api.github.com/repos/netguru/bob-the-bot/releases{/id}","deployments_url":"https://api.github.com/repos/netguru/bob-the-bot/deployments","created_at":"2018-07-17T07:35:10Z","updated_at":"2018-08-24T12:52:12Z","pushed_at":"2018-08-24T13:17:48Z","git_url":"git://github.com/netguru/bob-the-bot.git","ssh_url":"git@github.com:netguru/bob-the-bot.git","clone_url":"https://github.com/netguru/bob-the-bot.git","svn_url":"https://github.com/netguru/bob-the-bot","homepage":null,"size":180,"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":4,"license":null,"forks":0,"open_issues":4,"watchers":0,"default_branch":"master"}},"base":{"label":"netguru:master","ref":"master","sha":"0b0f29b3fcd77c922161ba5f5cf3ce855beffb58","user":{"login":"netguru","id":1146,"node_id":"MDEyOk9yZ2FuaXphdGlvbjExNDY=","avatar_url":"https://avatars1.githubusercontent.com/u/1146?v=4","gravatar_id":"","url":"https://api.github.com/users/netguru","html_url":"https://github.com/netguru","followers_url":"https://api.github.com/users/netguru/followers","following_url":"https://api.github.com/users/netguru/following{/other_user}","gists_url":"https://api.github.com/users/netguru/gists{/gist_id}","starred_url":"https://api.github.com/users/netguru/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/netguru/subscriptions","organizations_url":"https://api.github.com/users/netguru/orgs","repos_url":"https://api.github.com/users/netguru/repos","events_url":"https://api.github.com/users/netguru/events{/privacy}","received_events_url":"https://api.github.com/users/netguru/received_events","type":"Organization","site_admin":false},"repo":{"id":141249965,"node_id":"MDEwOlJlcG9zaXRvcnkxNDEyNDk5NjU=","name":"bob-the-bot","full_name":"netguru/bob-the-bot","owner":{"login":"netguru","id":1146,"node_id":"MDEyOk9yZ2FuaXphdGlvbjExNDY=","avatar_url":"https://avatars1.githubusercontent.com/u/1146?v=4","gravatar_id":"","url":"https://api.github.com/users/netguru","html_url":"https://github.com/netguru","followers_url":"https://api.github.com/users/netguru/followers","following_url":"https://api.github.com/users/netguru/following{/other_user}","gists_url":"https://api.github.com/users/netguru/gists{/gist_id}","starred_url":"https://api.github.com/users/netguru/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/netguru/subscriptions","organizations_url":"https://api.github.com/users/netguru/orgs","repos_url":"https://api.github.com/users/netguru/repos","events_url":"https://api.github.com/users/netguru/events{/privacy}","received_events_url":"https://api.github.com/users/netguru/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/netguru/bob-the-bot","description":null,"fork":false,"url":"https://api.github.com/repos/netguru/bob-the-bot","forks_url":"https://api.github.com/repos/netguru/bob-the-bot/forks","keys_url":"https://api.github.com/repos/netguru/bob-the-bot/keys{/key_id}","collaborators_url":"https://api.github.com/repos/netguru/bob-the-bot/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/netguru/bob-the-bot/teams","hooks_url":"https://api.github.com/repos/netguru/bob-the-bot/hooks","issue_events_url":"https://api.github.com/repos/netguru/bob-the-bot/issues/events{/number}","events_url":"https://api.github.com/repos/netguru/bob-the-bot/events","assignees_url":"https://api.github.com/repos/netguru/bob-the-bot/assignees{/user}","branches_url":"https://api.github.com/repos/netguru/bob-the-bot/branches{/branch}","tags_url":"https://api.github.com/repos/netguru/bob-the-bot/tags","blobs_url":"https://api.github.com/repos/netguru/bob-the-bot/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/netguru/bob-the-bot/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/netguru/bob-the-bot/git/refs{/sha}","trees_url":"https://api.github.com/repos/netguru/bob-the-bot/git/trees{/sha}","statuses_url":"https://api.github.com/repos/netguru/bob-the-bot/statuses/{sha}","languages_url":"https://api.github.com/repos/netguru/bob-the-bot/languages","stargazers_url":"https://api.github.com/repos/netguru/bob-the-bot/stargazers","contributors_url":"https://api.github.com/repos/netguru/bob-the-bot/contributors","subscribers_url":"https://api.github.com/repos/netguru/bob-the-bot/subscribers","subscription_url":"https://api.github.com/repos/netguru/bob-the-bot/subscription","commits_url":"https://api.github.com/repos/netguru/bob-the-bot/commits{/sha}","git_commits_url":"https://api.github.com/repos/netguru/bob-the-bot/git/commits{/sha}","comments_url":"https://api.github.com/repos/netguru/bob-the-bot/comments{/number}","issue_comment_url":"https://api.github.com/repos/netguru/bob-the-bot/issues/comments{/number}","contents_url":"https://api.github.com/repos/netguru/bob-the-bot/contents/{+path}","compare_url":"https://api.github.com/repos/netguru/bob-the-bot/compare/{base}...{head}","merges_url":"https://api.github.com/repos/netguru/bob-the-bot/merges","archive_url":"https://api.github.com/repos/netguru/bob-the-bot/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/netguru/bob-the-bot/downloads","issues_url":"https://api.github.com/repos/netguru/bob-the-bot/issues{/number}","pulls_url":"https://api.github.com/repos/netguru/bob-the-bot/pulls{/number}","milestones_url":"https://api.github.com/repos/netguru/bob-the-bot/milestones{/number}","notifications_url":"https://api.github.com/repos/netguru/bob-the-bot/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/netguru/bob-the-bot/labels{/name}","releases_url":"https://api.github.com/repos/netguru/bob-the-bot/releases{/id}","deployments_url":"https://api.github.com/repos/netguru/bob-the-bot/deployments","created_at":"2018-07-17T07:35:10Z","updated_at":"2018-08-24T12:52:12Z","pushed_at":"2018-08-24T13:17:48Z","git_url":"git://github.com/netguru/bob-the-bot.git","ssh_url":"git@github.com:netguru/bob-the-bot.git","clone_url":"https://github.com/netguru/bob-the-bot.git","svn_url":"https://github.com/netguru/bob-the-bot","homepage":null,"size":180,"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":4,"license":null,"forks":0,"open_issues":4,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/netguru/bob-the-bot/pulls/31"},"html":{"href":"https://github.com/netguru/bob-the-bot/pull/31"},"issue":{"href":"https://api.github.com/repos/netguru/bob-the-bot/issues/31"},"comments":{"href":"https://api.github.com/repos/netguru/bob-the-bot/issues/31/comments"},"review_comments":{"href":"https://api.github.com/repos/netguru/bob-the-bot/pulls/31/comments"},"review_comment":{"href":"https://api.github.com/repos/netguru/bob-the-bot/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/netguru/bob-the-bot/pulls/31/commits"},"statuses":{"href":"https://api.github.com/repos/netguru/bob-the-bot/statuses/988001a6a2705c9ba6ef18bdec6beb046d160c11"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"Davlis"}}