{"action":"created","comment":{"url":"https://api.github.com/repos/RocketChat/Rocket.Chat/pulls/comments/149219742","pull_request_review_id":74580783,"id":149219742,"diff_hunk":"@@ -16,16 +13,32 @@ Template.livechatTriggerCondition.helpers({\n \t\tif (this.name === condition) {\n \t\t\treturn this.value;\n \t\t}\n+\t},\n+\tlanguages() {\n+\t\tconst languages = TAPi18n.getLanguages();\n+\n+\t\tlet result = Object.keys(languages).map(key => {\n+\t\t\tconst language = languages[key];\n+\t\t\treturn _.extend(language, {key});\n+\t\t});\n+\n+\t\tresult = _.sortBy(result, 'key');","path":"packages/rocketchat-livechat/client/views/app/triggers/livechatTriggerCondition.js","position":24,"original_position":24,"commit_id":"2bbac4fb2fd83cbc1cea56955376f20ab36fefc6","original_commit_id":"2bbac4fb2fd83cbc1cea56955376f20ab36fefc6","user":{"login":"codacy-bot","id":19940114,"avatar_url":"https://avatars1.githubusercontent.com/u/19940114?v=4","gravatar_id":"","url":"https://api.github.com/users/codacy-bot","html_url":"https://github.com/codacy-bot","followers_url":"https://api.github.com/users/codacy-bot/followers","following_url":"https://api.github.com/users/codacy-bot/following{/other_user}","gists_url":"https://api.github.com/users/codacy-bot/gists{/gist_id}","starred_url":"https://api.github.com/users/codacy-bot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/codacy-bot/subscriptions","organizations_url":"https://api.github.com/users/codacy-bot/orgs","repos_url":"https://api.github.com/users/codacy-bot/repos","events_url":"https://api.github.com/users/codacy-bot/events{/privacy}","received_events_url":"https://api.github.com/users/codacy-bot/received_events","type":"User","site_admin":false},"body":"![Codacy](https://www.codacy.com/assets/images/favicon.png) Issue found: ['_' is not defined. (no-undef)](https://www.codacy.com/app/RocketChat/Rocket-Chat/pullRequest?prid=1024242)","created_at":"2017-11-06T22:13:59Z","updated_at":"2017-11-06T22:13:59Z","html_url":"https://github.com/RocketChat/Rocket.Chat/pull/8669#discussion_r149219742","pull_request_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/pulls/8669","author_association":"NONE","_links":{"self":{"href":"https://api.github.com/repos/RocketChat/Rocket.Chat/pulls/comments/149219742"},"html":{"href":"https://github.com/RocketChat/Rocket.Chat/pull/8669#discussion_r149219742"},"pull_request":{"href":"https://api.github.com/repos/RocketChat/Rocket.Chat/pulls/8669"}}},"pull_request":{"url":"https://api.github.com/repos/RocketChat/Rocket.Chat/pulls/8669","id":149051825,"html_url":"https://github.com/RocketChat/Rocket.Chat/pull/8669","diff_url":"https://github.com/RocketChat/Rocket.Chat/pull/8669.diff","patch_url":"https://github.com/RocketChat/Rocket.Chat/pull/8669.patch","issue_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/issues/8669","number":8669,"state":"open","locked":false,"title":"WIP: [NEW] Multiple trigger conditions for Livechat","user":{"login":"icosamuel","id":5400332,"avatar_url":"https://avatars0.githubusercontent.com/u/5400332?v=4","gravatar_id":"","url":"https://api.github.com/users/icosamuel","html_url":"https://github.com/icosamuel","followers_url":"https://api.github.com/users/icosamuel/followers","following_url":"https://api.github.com/users/icosamuel/following{/other_user}","gists_url":"https://api.github.com/users/icosamuel/gists{/gist_id}","starred_url":"https://api.github.com/users/icosamuel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/icosamuel/subscriptions","organizations_url":"https://api.github.com/users/icosamuel/orgs","repos_url":"https://api.github.com/users/icosamuel/repos","events_url":"https://api.github.com/users/icosamuel/events{/privacy}","received_events_url":"https://api.github.com/users/icosamuel/received_events","type":"User","site_admin":false},"body":"@RocketChat/core \r\nAddresses part of #1824\r\n\r\nNew ability to combine different conditions for the triggers already available in the Livechat settings.\r\nNew condition type where a trigger works according to the Livechat plugin's language.","created_at":"2017-10-26T21:36:02Z","updated_at":"2017-11-06T22:13:59Z","closed_at":null,"merged_at":null,"merge_commit_sha":"f2c06dda51c687931e143f8a829479d7b578b9eb","assignee":null,"assignees":[],"requested_reviewers":[],"milestone":null,"commits_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/pulls/8669/commits","review_comments_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/pulls/8669/comments","review_comment_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/pulls/comments{/number}","comments_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/issues/8669/comments","statuses_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/statuses/2bbac4fb2fd83cbc1cea56955376f20ab36fefc6","head":{"label":"icosamuel:feature/livechat_multiple_trigger_conditions","ref":"feature/livechat_multiple_trigger_conditions","sha":"2bbac4fb2fd83cbc1cea56955376f20ab36fefc6","user":{"login":"icosamuel","id":5400332,"avatar_url":"https://avatars0.githubusercontent.com/u/5400332?v=4","gravatar_id":"","url":"https://api.github.com/users/icosamuel","html_url":"https://github.com/icosamuel","followers_url":"https://api.github.com/users/icosamuel/followers","following_url":"https://api.github.com/users/icosamuel/following{/other_user}","gists_url":"https://api.github.com/users/icosamuel/gists{/gist_id}","starred_url":"https://api.github.com/users/icosamuel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/icosamuel/subscriptions","organizations_url":"https://api.github.com/users/icosamuel/orgs","repos_url":"https://api.github.com/users/icosamuel/repos","events_url":"https://api.github.com/users/icosamuel/events{/privacy}","received_events_url":"https://api.github.com/users/icosamuel/received_events","type":"User","site_admin":false},"repo":{"id":102514389,"name":"Rocket.Chat","full_name":"icosamuel/Rocket.Chat","owner":{"login":"icosamuel","id":5400332,"avatar_url":"https://avatars0.githubusercontent.com/u/5400332?v=4","gravatar_id":"","url":"https://api.github.com/users/icosamuel","html_url":"https://github.com/icosamuel","followers_url":"https://api.github.com/users/icosamuel/followers","following_url":"https://api.github.com/users/icosamuel/following{/other_user}","gists_url":"https://api.github.com/users/icosamuel/gists{/gist_id}","starred_url":"https://api.github.com/users/icosamuel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/icosamuel/subscriptions","organizations_url":"https://api.github.com/users/icosamuel/orgs","repos_url":"https://api.github.com/users/icosamuel/repos","events_url":"https://api.github.com/users/icosamuel/events{/privacy}","received_events_url":"https://api.github.com/users/icosamuel/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/icosamuel/Rocket.Chat","description":"Have your own Slack like online chat, built with Meteor.","fork":true,"url":"https://api.github.com/repos/icosamuel/Rocket.Chat","forks_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/forks","keys_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/keys{/key_id}","collaborators_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/teams","hooks_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/hooks","issue_events_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/issues/events{/number}","events_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/events","assignees_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/assignees{/user}","branches_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/branches{/branch}","tags_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/tags","blobs_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/git/refs{/sha}","trees_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/git/trees{/sha}","statuses_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/statuses/{sha}","languages_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/languages","stargazers_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/stargazers","contributors_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/contributors","subscribers_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/subscribers","subscription_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/subscription","commits_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/commits{/sha}","git_commits_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/git/commits{/sha}","comments_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/comments{/number}","issue_comment_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/issues/comments{/number}","contents_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/contents/{+path}","compare_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/compare/{base}...{head}","merges_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/merges","archive_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/downloads","issues_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/issues{/number}","pulls_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/pulls{/number}","milestones_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/milestones{/number}","notifications_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/labels{/name}","releases_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/releases{/id}","deployments_url":"https://api.github.com/repos/icosamuel/Rocket.Chat/deployments","created_at":"2017-09-05T18:10:50Z","updated_at":"2017-09-05T18:10:56Z","pushed_at":"2017-11-06T22:08:02Z","git_url":"git://github.com/icosamuel/Rocket.Chat.git","ssh_url":"git@github.com:icosamuel/Rocket.Chat.git","clone_url":"https://github.com/icosamuel/Rocket.Chat.git","svn_url":"https://github.com/icosamuel/Rocket.Chat","homepage":"https://rocket.chat/","size":54692,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"develop"}},"base":{"label":"RocketChat:develop","ref":"develop","sha":"217073f4c010e8472a7521c998e89fd47c7a68ee","user":{"login":"RocketChat","id":12508788,"avatar_url":"https://avatars1.githubusercontent.com/u/12508788?v=4","gravatar_id":"","url":"https://api.github.com/users/RocketChat","html_url":"https://github.com/RocketChat","followers_url":"https://api.github.com/users/RocketChat/followers","following_url":"https://api.github.com/users/RocketChat/following{/other_user}","gists_url":"https://api.github.com/users/RocketChat/gists{/gist_id}","starred_url":"https://api.github.com/users/RocketChat/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/RocketChat/subscriptions","organizations_url":"https://api.github.com/users/RocketChat/orgs","repos_url":"https://api.github.com/users/RocketChat/repos","events_url":"https://api.github.com/users/RocketChat/events{/privacy}","received_events_url":"https://api.github.com/users/RocketChat/received_events","type":"Organization","site_admin":false},"repo":{"id":35866694,"name":"Rocket.Chat","full_name":"RocketChat/Rocket.Chat","owner":{"login":"RocketChat","id":12508788,"avatar_url":"https://avatars1.githubusercontent.com/u/12508788?v=4","gravatar_id":"","url":"https://api.github.com/users/RocketChat","html_url":"https://github.com/RocketChat","followers_url":"https://api.github.com/users/RocketChat/followers","following_url":"https://api.github.com/users/RocketChat/following{/other_user}","gists_url":"https://api.github.com/users/RocketChat/gists{/gist_id}","starred_url":"https://api.github.com/users/RocketChat/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/RocketChat/subscriptions","organizations_url":"https://api.github.com/users/RocketChat/orgs","repos_url":"https://api.github.com/users/RocketChat/repos","events_url":"https://api.github.com/users/RocketChat/events{/privacy}","received_events_url":"https://api.github.com/users/RocketChat/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/RocketChat/Rocket.Chat","description":"Have your own Slack like online chat, built with Meteor.","fork":false,"url":"https://api.github.com/repos/RocketChat/Rocket.Chat","forks_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/forks","keys_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/keys{/key_id}","collaborators_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/teams","hooks_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/hooks","issue_events_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/issues/events{/number}","events_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/events","assignees_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/assignees{/user}","branches_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/branches{/branch}","tags_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/tags","blobs_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/git/refs{/sha}","trees_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/git/trees{/sha}","statuses_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/statuses/{sha}","languages_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/languages","stargazers_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/stargazers","contributors_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/contributors","subscribers_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/subscribers","subscription_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/subscription","commits_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/commits{/sha}","git_commits_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/git/commits{/sha}","comments_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/comments{/number}","issue_comment_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/issues/comments{/number}","contents_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/contents/{+path}","compare_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/compare/{base}...{head}","merges_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/merges","archive_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/downloads","issues_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/issues{/number}","pulls_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/pulls{/number}","milestones_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/milestones{/number}","notifications_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/labels{/name}","releases_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/releases{/id}","deployments_url":"https://api.github.com/repos/RocketChat/Rocket.Chat/deployments","created_at":"2015-05-19T07:36:09Z","updated_at":"2017-11-06T22:07:19Z","pushed_at":"2017-11-06T22:08:05Z","git_url":"git://github.com/RocketChat/Rocket.Chat.git","ssh_url":"git@github.com:RocketChat/Rocket.Chat.git","clone_url":"https://github.com/RocketChat/Rocket.Chat.git","svn_url":"https://github.com/RocketChat/Rocket.Chat","homepage":"https://rocket.chat/","size":55484,"stargazers_count":14765,"watchers_count":14765,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":3129,"mirror_url":null,"archived":false,"open_issues_count":2186,"forks":3129,"open_issues":2186,"watchers":14765,"default_branch":"develop"}},"_links":{"self":{"href":"https://api.github.com/repos/RocketChat/Rocket.Chat/pulls/8669"},"html":{"href":"https://github.com/RocketChat/Rocket.Chat/pull/8669"},"issue":{"href":"https://api.github.com/repos/RocketChat/Rocket.Chat/issues/8669"},"comments":{"href":"https://api.github.com/repos/RocketChat/Rocket.Chat/issues/8669/comments"},"review_comments":{"href":"https://api.github.com/repos/RocketChat/Rocket.Chat/pulls/8669/comments"},"review_comment":{"href":"https://api.github.com/repos/RocketChat/Rocket.Chat/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/RocketChat/Rocket.Chat/pulls/8669/commits"},"statuses":{"href":"https://api.github.com/repos/RocketChat/Rocket.Chat/statuses/2bbac4fb2fd83cbc1cea56955376f20ab36fefc6"}},"author_association":"NONE"}}
{"actor":{"display_login":"codacy-bot"}}