{"action":"created","comment":{"url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/pulls/comments/224999294","pull_request_review_id":164505264,"id":224999294,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIyNDk5OTI5NA==","diff_hunk":"@@ -175,6 +176,52 @@ var callback = []\n \n bot.use((ctx, next) => telegrafStart(ctx, next))\n \n+var locales = [\n+\t'pt',\n+\t//'en'\n+]\n+const r = new Resources()\n+locales.forEach((id) => {\n+\tr.load(id, `locales/${id}.po`)\n+})\n+\n+const checkLanguage = (ctx) => {\n+\tvar language = 'pt'\n+\tvar types = [\n+\t\t'message',\n+\t\t'edited_message',\n+\t\t'callback_query',\n+\t\t'inline_query'\n+\t]\n+\tif (ctx && ctx.update) {\n+\t\tvar type = types.find((t) => ctx.update[t])\n+\t\tif (type && ctx.update[type]) {\n+\t\t\tif (type == 'message' || type == 'edited_message') {\n+\t\t\t\tif (ctx.update[type].chat && ctx.update[type].chat.id) {","path":"index.js","position":42,"original_position":42,"commit_id":"200047405605f1536f8c47d5358eb88e18ebc38e","original_commit_id":"200047405605f1536f8c47d5358eb88e18ebc38e","user":{"login":"codacy-bot","id":19940114,"node_id":"MDQ6VXNlcjE5OTQwMTE0","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://app.codacy.com/assets/images/favicon.png) Issue found: [Generic Object Injection Sink (security/detect-object-injection)](https://app.codacy.com/app/tiagodanin/EDPlugins/pullRequest?prid=2359364)","created_at":"2018-10-14T16:33:38Z","updated_at":"2018-10-14T16:33:38Z","html_url":"https://github.com/SynkoDevelopers/EDPlugins/pull/29#discussion_r224999294","pull_request_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/pulls/29","author_association":"NONE","_links":{"self":{"href":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/pulls/comments/224999294"},"html":{"href":"https://github.com/SynkoDevelopers/EDPlugins/pull/29#discussion_r224999294"},"pull_request":{"href":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/pulls/29"}}},"pull_request":{"url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/pulls/29","id":222726730,"node_id":"MDExOlB1bGxSZXF1ZXN0MjIyNzI2NzMw","html_url":"https://github.com/SynkoDevelopers/EDPlugins/pull/29","diff_url":"https://github.com/SynkoDevelopers/EDPlugins/pull/29.diff","patch_url":"https://github.com/SynkoDevelopers/EDPlugins/pull/29.patch","issue_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/issues/29","number":29,"state":"open","locked":false,"title":"WIP: i18n","user":{"login":"TiagoDanin","id":5731176,"node_id":"MDQ6VXNlcjU3MzExNzY=","avatar_url":"https://avatars3.githubusercontent.com/u/5731176?v=4","gravatar_id":"","url":"https://api.github.com/users/TiagoDanin","html_url":"https://github.com/TiagoDanin","followers_url":"https://api.github.com/users/TiagoDanin/followers","following_url":"https://api.github.com/users/TiagoDanin/following{/other_user}","gists_url":"https://api.github.com/users/TiagoDanin/gists{/gist_id}","starred_url":"https://api.github.com/users/TiagoDanin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/TiagoDanin/subscriptions","organizations_url":"https://api.github.com/users/TiagoDanin/orgs","repos_url":"https://api.github.com/users/TiagoDanin/repos","events_url":"https://api.github.com/users/TiagoDanin/events{/privacy}","received_events_url":"https://api.github.com/users/TiagoDanin/received_events","type":"User","site_admin":false},"body":"","created_at":"2018-10-14T16:32:01Z","updated_at":"2018-10-14T16:33:38Z","closed_at":null,"merged_at":null,"merge_commit_sha":"5ba3499db74b79e6c1c87f68127b4003fb565616","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/pulls/29/commits","review_comments_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/pulls/29/comments","review_comment_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/pulls/comments{/number}","comments_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/issues/29/comments","statuses_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/statuses/200047405605f1536f8c47d5358eb88e18ebc38e","head":{"label":"SynkoDevelopers:translation","ref":"translation","sha":"200047405605f1536f8c47d5358eb88e18ebc38e","user":{"login":"SynkoDevelopers","id":24530637,"node_id":"MDEyOk9yZ2FuaXphdGlvbjI0NTMwNjM3","avatar_url":"https://avatars0.githubusercontent.com/u/24530637?v=4","gravatar_id":"","url":"https://api.github.com/users/SynkoDevelopers","html_url":"https://github.com/SynkoDevelopers","followers_url":"https://api.github.com/users/SynkoDevelopers/followers","following_url":"https://api.github.com/users/SynkoDevelopers/following{/other_user}","gists_url":"https://api.github.com/users/SynkoDevelopers/gists{/gist_id}","starred_url":"https://api.github.com/users/SynkoDevelopers/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SynkoDevelopers/subscriptions","organizations_url":"https://api.github.com/users/SynkoDevelopers/orgs","repos_url":"https://api.github.com/users/SynkoDevelopers/repos","events_url":"https://api.github.com/users/SynkoDevelopers/events{/privacy}","received_events_url":"https://api.github.com/users/SynkoDevelopers/received_events","type":"Organization","site_admin":false},"repo":{"id":136814089,"node_id":"MDEwOlJlcG9zaXRvcnkxMzY4MTQwODk=","name":"EDPlugins","full_name":"SynkoDevelopers/EDPlugins","private":false,"owner":{"login":"SynkoDevelopers","id":24530637,"node_id":"MDEyOk9yZ2FuaXphdGlvbjI0NTMwNjM3","avatar_url":"https://avatars0.githubusercontent.com/u/24530637?v=4","gravatar_id":"","url":"https://api.github.com/users/SynkoDevelopers","html_url":"https://github.com/SynkoDevelopers","followers_url":"https://api.github.com/users/SynkoDevelopers/followers","following_url":"https://api.github.com/users/SynkoDevelopers/following{/other_user}","gists_url":"https://api.github.com/users/SynkoDevelopers/gists{/gist_id}","starred_url":"https://api.github.com/users/SynkoDevelopers/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SynkoDevelopers/subscriptions","organizations_url":"https://api.github.com/users/SynkoDevelopers/orgs","repos_url":"https://api.github.com/users/SynkoDevelopers/repos","events_url":"https://api.github.com/users/SynkoDevelopers/events{/privacy}","received_events_url":"https://api.github.com/users/SynkoDevelopers/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/SynkoDevelopers/EDPlugins","description":"Plugins para nova versão do https://t.me/EdRobot","fork":false,"url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins","forks_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/forks","keys_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/keys{/key_id}","collaborators_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/teams","hooks_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/hooks","issue_events_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/issues/events{/number}","events_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/events","assignees_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/assignees{/user}","branches_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/branches{/branch}","tags_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/tags","blobs_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/git/refs{/sha}","trees_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/git/trees{/sha}","statuses_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/statuses/{sha}","languages_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/languages","stargazers_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/stargazers","contributors_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/contributors","subscribers_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/subscribers","subscription_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/subscription","commits_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/commits{/sha}","git_commits_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/git/commits{/sha}","comments_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/comments{/number}","issue_comment_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/issues/comments{/number}","contents_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/contents/{+path}","compare_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/compare/{base}...{head}","merges_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/merges","archive_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/downloads","issues_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/issues{/number}","pulls_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/pulls{/number}","milestones_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/milestones{/number}","notifications_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/labels{/name}","releases_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/releases{/id}","deployments_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/deployments","created_at":"2018-06-10T14:05:31Z","updated_at":"2018-10-09T11:57:37Z","pushed_at":"2018-10-14T16:32:01Z","git_url":"git://github.com/SynkoDevelopers/EDPlugins.git","ssh_url":"git@github.com:SynkoDevelopers/EDPlugins.git","clone_url":"https://github.com/SynkoDevelopers/EDPlugins.git","svn_url":"https://github.com/SynkoDevelopers/EDPlugins","homepage":"https://synko.com.br","size":113,"stargazers_count":2,"watchers_count":2,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":5,"mirror_url":null,"archived":false,"open_issues_count":6,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":5,"open_issues":6,"watchers":2,"default_branch":"master"}},"base":{"label":"SynkoDevelopers:master","ref":"master","sha":"7505324169236f657e7d9b3fac88ae29b7ae72be","user":{"login":"SynkoDevelopers","id":24530637,"node_id":"MDEyOk9yZ2FuaXphdGlvbjI0NTMwNjM3","avatar_url":"https://avatars0.githubusercontent.com/u/24530637?v=4","gravatar_id":"","url":"https://api.github.com/users/SynkoDevelopers","html_url":"https://github.com/SynkoDevelopers","followers_url":"https://api.github.com/users/SynkoDevelopers/followers","following_url":"https://api.github.com/users/SynkoDevelopers/following{/other_user}","gists_url":"https://api.github.com/users/SynkoDevelopers/gists{/gist_id}","starred_url":"https://api.github.com/users/SynkoDevelopers/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SynkoDevelopers/subscriptions","organizations_url":"https://api.github.com/users/SynkoDevelopers/orgs","repos_url":"https://api.github.com/users/SynkoDevelopers/repos","events_url":"https://api.github.com/users/SynkoDevelopers/events{/privacy}","received_events_url":"https://api.github.com/users/SynkoDevelopers/received_events","type":"Organization","site_admin":false},"repo":{"id":136814089,"node_id":"MDEwOlJlcG9zaXRvcnkxMzY4MTQwODk=","name":"EDPlugins","full_name":"SynkoDevelopers/EDPlugins","private":false,"owner":{"login":"SynkoDevelopers","id":24530637,"node_id":"MDEyOk9yZ2FuaXphdGlvbjI0NTMwNjM3","avatar_url":"https://avatars0.githubusercontent.com/u/24530637?v=4","gravatar_id":"","url":"https://api.github.com/users/SynkoDevelopers","html_url":"https://github.com/SynkoDevelopers","followers_url":"https://api.github.com/users/SynkoDevelopers/followers","following_url":"https://api.github.com/users/SynkoDevelopers/following{/other_user}","gists_url":"https://api.github.com/users/SynkoDevelopers/gists{/gist_id}","starred_url":"https://api.github.com/users/SynkoDevelopers/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SynkoDevelopers/subscriptions","organizations_url":"https://api.github.com/users/SynkoDevelopers/orgs","repos_url":"https://api.github.com/users/SynkoDevelopers/repos","events_url":"https://api.github.com/users/SynkoDevelopers/events{/privacy}","received_events_url":"https://api.github.com/users/SynkoDevelopers/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/SynkoDevelopers/EDPlugins","description":"Plugins para nova versão do https://t.me/EdRobot","fork":false,"url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins","forks_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/forks","keys_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/keys{/key_id}","collaborators_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/teams","hooks_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/hooks","issue_events_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/issues/events{/number}","events_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/events","assignees_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/assignees{/user}","branches_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/branches{/branch}","tags_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/tags","blobs_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/git/refs{/sha}","trees_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/git/trees{/sha}","statuses_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/statuses/{sha}","languages_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/languages","stargazers_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/stargazers","contributors_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/contributors","subscribers_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/subscribers","subscription_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/subscription","commits_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/commits{/sha}","git_commits_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/git/commits{/sha}","comments_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/comments{/number}","issue_comment_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/issues/comments{/number}","contents_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/contents/{+path}","compare_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/compare/{base}...{head}","merges_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/merges","archive_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/downloads","issues_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/issues{/number}","pulls_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/pulls{/number}","milestones_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/milestones{/number}","notifications_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/labels{/name}","releases_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/releases{/id}","deployments_url":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/deployments","created_at":"2018-06-10T14:05:31Z","updated_at":"2018-10-09T11:57:37Z","pushed_at":"2018-10-14T16:32:01Z","git_url":"git://github.com/SynkoDevelopers/EDPlugins.git","ssh_url":"git@github.com:SynkoDevelopers/EDPlugins.git","clone_url":"https://github.com/SynkoDevelopers/EDPlugins.git","svn_url":"https://github.com/SynkoDevelopers/EDPlugins","homepage":"https://synko.com.br","size":113,"stargazers_count":2,"watchers_count":2,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":5,"mirror_url":null,"archived":false,"open_issues_count":6,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":5,"open_issues":6,"watchers":2,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/pulls/29"},"html":{"href":"https://github.com/SynkoDevelopers/EDPlugins/pull/29"},"issue":{"href":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/issues/29"},"comments":{"href":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/issues/29/comments"},"review_comments":{"href":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/pulls/29/comments"},"review_comment":{"href":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/pulls/29/commits"},"statuses":{"href":"https://api.github.com/repos/SynkoDevelopers/EDPlugins/statuses/200047405605f1536f8c47d5358eb88e18ebc38e"}},"author_association":"MEMBER"}}
{"actor":{"display_login":"codacy-bot"}}