{"action":"created","comment":{"url":"https://api.github.com/repos/stream-labs/streamlabs-obs/pulls/comments/325436410","pull_request_review_id":289612351,"id":325436410,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDMyNTQzNjQxMA==","diff_hunk":"@@ -37,120 +41,114 @@ export default class EventFilterMenu extends TsxComponent<{}> {\n     return this.resubFilters.hasOwnProperty('resub') && this.resubFilters['resub'].value;\n   }\n \n-  updateFilter(filter: string, value: any) {\n+  updateFilter(filter: string, value: boolean | number) {\n     this.recentEventsService.updateFilterPreference(filter, value);\n   }\n \n+  renderBooleanInput(\n+    h: Function,\n+    key: string,\n+    filter: { name: string; value: boolean },\n+    header: boolean = false,\n+  ) {\n+    return (\n+      <BoolInput\n+        value={filter.value}\n+        metadata={{ title: $t(filter.name) }}\n+        onInput={(value: boolean) => this.updateFilter(key, value)}\n+        class={header ? styles.categoryHeader : ''}\n+      />\n+    );\n+  }\n+\n+  renderGeneralFilters(h: Function) {\n+    return (\n+      <div class={styles.halfWidth}>\n+        <h2>{$t('General')}</h2>\n+        {Object.keys(this.mainFilters).map(filter => (\n+          <div>{this.renderBooleanInput(h, filter, this.mainFilters[filter])}</div>\n+        ))}\n+      </div>\n+    );\n+  }\n+\n+  renderSubFilters(h: Function) {\n+    return (\n+      <div class={styles.halfWidth}>\n+        {Object.keys(this.subFilters).map(\n+          filter =>\n+            filter === 'subscription' && (\n+              <div>{this.renderBooleanInput(h, filter, this.subFilters[filter], true)}</div>\n+            ),\n+        )}\n+        {Object.keys(this.subFilters).map(\n+          filter =>\n+            filter !== 'subscription' &&\n+            this.subsEnabled && (\n+              <div>{this.renderBooleanInput(h, filter, this.subFilters[filter])}</div>\n+            ),\n+        )}\n+      </div>\n+    );\n+  }\n+\n+  renderResubFilters(h: Function) {","path":"app/components/windows/EventFilterMenu.tsx","position":67,"original_position":67,"commit_id":"506598dbd678cf8bd4f05f6eeaf594b36d939d08","original_commit_id":"506598dbd678cf8bd4f05f6eeaf594b36d939d08","user":{"login":"codeclimate[bot]","id":36754821,"node_id":"MDM6Qm90MzY3NTQ4MjE=","avatar_url":"https://avatars0.githubusercontent.com/in/9403?v=4","gravatar_id":"","url":"https://api.github.com/users/codeclimate%5Bbot%5D","html_url":"https://github.com/apps/codeclimate","followers_url":"https://api.github.com/users/codeclimate%5Bbot%5D/followers","following_url":"https://api.github.com/users/codeclimate%5Bbot%5D/following{/other_user}","gists_url":"https://api.github.com/users/codeclimate%5Bbot%5D/gists{/gist_id}","starred_url":"https://api.github.com/users/codeclimate%5Bbot%5D/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/codeclimate%5Bbot%5D/subscriptions","organizations_url":"https://api.github.com/users/codeclimate%5Bbot%5D/orgs","repos_url":"https://api.github.com/users/codeclimate%5Bbot%5D/repos","events_url":"https://api.github.com/users/codeclimate%5Bbot%5D/events{/privacy}","received_events_url":"https://api.github.com/users/codeclimate%5Bbot%5D/received_events","type":"Bot","site_admin":false},"body":"Function `renderResubFilters` has 45 lines of code (exceeds 32 allowed). Consider refactoring.","created_at":"2019-09-18T00:14:34Z","updated_at":"2019-09-18T00:14:34Z","html_url":"https://github.com/stream-labs/streamlabs-obs/pull/2105#discussion_r325436410","pull_request_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/pulls/2105","author_association":"NONE","_links":{"self":{"href":"https://api.github.com/repos/stream-labs/streamlabs-obs/pulls/comments/325436410"},"html":{"href":"https://github.com/stream-labs/streamlabs-obs/pull/2105#discussion_r325436410"},"pull_request":{"href":"https://api.github.com/repos/stream-labs/streamlabs-obs/pulls/2105"}}},"pull_request":{"url":"https://api.github.com/repos/stream-labs/streamlabs-obs/pulls/2105","id":318526517,"node_id":"MDExOlB1bGxSZXF1ZXN0MzE4NTI2NTE3","html_url":"https://github.com/stream-labs/streamlabs-obs/pull/2105","diff_url":"https://github.com/stream-labs/streamlabs-obs/pull/2105.diff","patch_url":"https://github.com/stream-labs/streamlabs-obs/pull/2105.patch","issue_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/issues/2105","number":2105,"state":"open","locked":false,"title":"improve typing on filter configs","user":{"login":"andycreeth","id":3180181,"node_id":"MDQ6VXNlcjMxODAxODE=","avatar_url":"https://avatars1.githubusercontent.com/u/3180181?v=4","gravatar_id":"","url":"https://api.github.com/users/andycreeth","html_url":"https://github.com/andycreeth","followers_url":"https://api.github.com/users/andycreeth/followers","following_url":"https://api.github.com/users/andycreeth/following{/other_user}","gists_url":"https://api.github.com/users/andycreeth/gists{/gist_id}","starred_url":"https://api.github.com/users/andycreeth/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andycreeth/subscriptions","organizations_url":"https://api.github.com/users/andycreeth/orgs","repos_url":"https://api.github.com/users/andycreeth/repos","events_url":"https://api.github.com/users/andycreeth/events{/privacy}","received_events_url":"https://api.github.com/users/andycreeth/received_events","type":"User","site_admin":false},"body":"","created_at":"2019-09-17T21:08:07Z","updated_at":"2019-09-18T00:14:34Z","closed_at":null,"merged_at":null,"merge_commit_sha":"20e122ffb5f46ea9847cec0ec465740243f868f8","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/pulls/2105/commits","review_comments_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/pulls/2105/comments","review_comment_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/pulls/comments{/number}","comments_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/issues/2105/comments","statuses_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/statuses/506598dbd678cf8bd4f05f6eeaf594b36d939d08","head":{"label":"stream-labs:recent_events_typing_improvements","ref":"recent_events_typing_improvements","sha":"506598dbd678cf8bd4f05f6eeaf594b36d939d08","user":{"login":"stream-labs","id":33038602,"node_id":"MDEyOk9yZ2FuaXphdGlvbjMzMDM4NjAy","avatar_url":"https://avatars3.githubusercontent.com/u/33038602?v=4","gravatar_id":"","url":"https://api.github.com/users/stream-labs","html_url":"https://github.com/stream-labs","followers_url":"https://api.github.com/users/stream-labs/followers","following_url":"https://api.github.com/users/stream-labs/following{/other_user}","gists_url":"https://api.github.com/users/stream-labs/gists{/gist_id}","starred_url":"https://api.github.com/users/stream-labs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stream-labs/subscriptions","organizations_url":"https://api.github.com/users/stream-labs/orgs","repos_url":"https://api.github.com/users/stream-labs/repos","events_url":"https://api.github.com/users/stream-labs/events{/privacy}","received_events_url":"https://api.github.com/users/stream-labs/received_events","type":"Organization","site_admin":false},"repo":{"id":108469351,"node_id":"MDEwOlJlcG9zaXRvcnkxMDg0NjkzNTE=","name":"streamlabs-obs","full_name":"stream-labs/streamlabs-obs","private":false,"owner":{"login":"stream-labs","id":33038602,"node_id":"MDEyOk9yZ2FuaXphdGlvbjMzMDM4NjAy","avatar_url":"https://avatars3.githubusercontent.com/u/33038602?v=4","gravatar_id":"","url":"https://api.github.com/users/stream-labs","html_url":"https://github.com/stream-labs","followers_url":"https://api.github.com/users/stream-labs/followers","following_url":"https://api.github.com/users/stream-labs/following{/other_user}","gists_url":"https://api.github.com/users/stream-labs/gists{/gist_id}","starred_url":"https://api.github.com/users/stream-labs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stream-labs/subscriptions","organizations_url":"https://api.github.com/users/stream-labs/orgs","repos_url":"https://api.github.com/users/stream-labs/repos","events_url":"https://api.github.com/users/stream-labs/events{/privacy}","received_events_url":"https://api.github.com/users/stream-labs/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/stream-labs/streamlabs-obs","description":"Free and open source streaming software built on OBS and Electron.","fork":false,"url":"https://api.github.com/repos/stream-labs/streamlabs-obs","forks_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/forks","keys_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/keys{/key_id}","collaborators_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/teams","hooks_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/hooks","issue_events_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/issues/events{/number}","events_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/events","assignees_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/assignees{/user}","branches_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/branches{/branch}","tags_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/tags","blobs_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/git/refs{/sha}","trees_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/git/trees{/sha}","statuses_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/statuses/{sha}","languages_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/languages","stargazers_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/stargazers","contributors_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/contributors","subscribers_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/subscribers","subscription_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/subscription","commits_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/commits{/sha}","git_commits_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/git/commits{/sha}","comments_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/comments{/number}","issue_comment_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/issues/comments{/number}","contents_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/contents/{+path}","compare_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/compare/{base}...{head}","merges_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/merges","archive_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/downloads","issues_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/issues{/number}","pulls_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/pulls{/number}","milestones_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/milestones{/number}","notifications_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/labels{/name}","releases_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/releases{/id}","deployments_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/deployments","created_at":"2017-10-26T21:50:19Z","updated_at":"2019-09-17T22:51:39Z","pushed_at":"2019-09-18T00:13:17Z","git_url":"git://github.com/stream-labs/streamlabs-obs.git","ssh_url":"git@github.com:stream-labs/streamlabs-obs.git","clone_url":"https://github.com/stream-labs/streamlabs-obs.git","svn_url":"https://github.com/stream-labs/streamlabs-obs","homepage":"https://streamlabs.com/streamlabs-obs","size":171386,"stargazers_count":894,"watchers_count":894,"language":"TypeScript","has_issues":false,"has_projects":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":206,"mirror_url":null,"archived":false,"disabled":false,"open_issues_count":14,"license":{"key":"gpl-3.0","name":"GNU General Public License v3.0","spdx_id":"GPL-3.0","url":"https://api.github.com/licenses/gpl-3.0","node_id":"MDc6TGljZW5zZTk="},"forks":206,"open_issues":14,"watchers":894,"default_branch":"staging"}},"base":{"label":"stream-labs:staging","ref":"staging","sha":"574e22af1b3a1d3880d06d0f732f7ad2545b3b38","user":{"login":"stream-labs","id":33038602,"node_id":"MDEyOk9yZ2FuaXphdGlvbjMzMDM4NjAy","avatar_url":"https://avatars3.githubusercontent.com/u/33038602?v=4","gravatar_id":"","url":"https://api.github.com/users/stream-labs","html_url":"https://github.com/stream-labs","followers_url":"https://api.github.com/users/stream-labs/followers","following_url":"https://api.github.com/users/stream-labs/following{/other_user}","gists_url":"https://api.github.com/users/stream-labs/gists{/gist_id}","starred_url":"https://api.github.com/users/stream-labs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stream-labs/subscriptions","organizations_url":"https://api.github.com/users/stream-labs/orgs","repos_url":"https://api.github.com/users/stream-labs/repos","events_url":"https://api.github.com/users/stream-labs/events{/privacy}","received_events_url":"https://api.github.com/users/stream-labs/received_events","type":"Organization","site_admin":false},"repo":{"id":108469351,"node_id":"MDEwOlJlcG9zaXRvcnkxMDg0NjkzNTE=","name":"streamlabs-obs","full_name":"stream-labs/streamlabs-obs","private":false,"owner":{"login":"stream-labs","id":33038602,"node_id":"MDEyOk9yZ2FuaXphdGlvbjMzMDM4NjAy","avatar_url":"https://avatars3.githubusercontent.com/u/33038602?v=4","gravatar_id":"","url":"https://api.github.com/users/stream-labs","html_url":"https://github.com/stream-labs","followers_url":"https://api.github.com/users/stream-labs/followers","following_url":"https://api.github.com/users/stream-labs/following{/other_user}","gists_url":"https://api.github.com/users/stream-labs/gists{/gist_id}","starred_url":"https://api.github.com/users/stream-labs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stream-labs/subscriptions","organizations_url":"https://api.github.com/users/stream-labs/orgs","repos_url":"https://api.github.com/users/stream-labs/repos","events_url":"https://api.github.com/users/stream-labs/events{/privacy}","received_events_url":"https://api.github.com/users/stream-labs/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/stream-labs/streamlabs-obs","description":"Free and open source streaming software built on OBS and Electron.","fork":false,"url":"https://api.github.com/repos/stream-labs/streamlabs-obs","forks_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/forks","keys_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/keys{/key_id}","collaborators_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/teams","hooks_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/hooks","issue_events_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/issues/events{/number}","events_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/events","assignees_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/assignees{/user}","branches_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/branches{/branch}","tags_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/tags","blobs_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/git/refs{/sha}","trees_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/git/trees{/sha}","statuses_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/statuses/{sha}","languages_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/languages","stargazers_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/stargazers","contributors_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/contributors","subscribers_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/subscribers","subscription_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/subscription","commits_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/commits{/sha}","git_commits_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/git/commits{/sha}","comments_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/comments{/number}","issue_comment_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/issues/comments{/number}","contents_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/contents/{+path}","compare_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/compare/{base}...{head}","merges_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/merges","archive_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/downloads","issues_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/issues{/number}","pulls_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/pulls{/number}","milestones_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/milestones{/number}","notifications_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/labels{/name}","releases_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/releases{/id}","deployments_url":"https://api.github.com/repos/stream-labs/streamlabs-obs/deployments","created_at":"2017-10-26T21:50:19Z","updated_at":"2019-09-17T22:51:39Z","pushed_at":"2019-09-18T00:13:17Z","git_url":"git://github.com/stream-labs/streamlabs-obs.git","ssh_url":"git@github.com:stream-labs/streamlabs-obs.git","clone_url":"https://github.com/stream-labs/streamlabs-obs.git","svn_url":"https://github.com/stream-labs/streamlabs-obs","homepage":"https://streamlabs.com/streamlabs-obs","size":171386,"stargazers_count":894,"watchers_count":894,"language":"TypeScript","has_issues":false,"has_projects":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":206,"mirror_url":null,"archived":false,"disabled":false,"open_issues_count":14,"license":{"key":"gpl-3.0","name":"GNU General Public License v3.0","spdx_id":"GPL-3.0","url":"https://api.github.com/licenses/gpl-3.0","node_id":"MDc6TGljZW5zZTk="},"forks":206,"open_issues":14,"watchers":894,"default_branch":"staging"}},"_links":{"self":{"href":"https://api.github.com/repos/stream-labs/streamlabs-obs/pulls/2105"},"html":{"href":"https://github.com/stream-labs/streamlabs-obs/pull/2105"},"issue":{"href":"https://api.github.com/repos/stream-labs/streamlabs-obs/issues/2105"},"comments":{"href":"https://api.github.com/repos/stream-labs/streamlabs-obs/issues/2105/comments"},"review_comments":{"href":"https://api.github.com/repos/stream-labs/streamlabs-obs/pulls/2105/comments"},"review_comment":{"href":"https://api.github.com/repos/stream-labs/streamlabs-obs/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/stream-labs/streamlabs-obs/pulls/2105/commits"},"statuses":{"href":"https://api.github.com/repos/stream-labs/streamlabs-obs/statuses/506598dbd678cf8bd4f05f6eeaf594b36d939d08"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"codeclimate"}}