{"action":"created","comment":{"url":"https://api.github.com/repos/cssinjs/theming/pulls/comments/144692579","pull_request_review_id":69390505,"id":144692579,"diff_hunk":"@@ -292,18 +290,33 @@ themeListener is an `Object` with following fields:\n     * context `Object`, where `context` is `this.context` from your component\n     * callback `Function`, which in turn will be invoked with theme update `Object`, every time theme is updated in `ThemeProvider`\n   * meant to be used in `componentDidMount`\n-  * returns unsubscribe `Function`, which you should invoke in `componentWillUnmount`\n+  * returns subscriptionId `Number`, which you should use to unsubscribe in `componentWillUnmount`\n   * example:\n     ```js\n     componentDidMount() {\n-      this.unsubscribe = themeListener.subscribe(this.context, theme => this.setState({ theme }));\n+      this.subscriptionId = themeListener.subscribe(this.context, theme => this.setState({ theme }));\n     }\n     componentWillUnmount() {\n-      if (typeof this.unsubscribe === 'function') {\n-        this.unsubscribe();\n-      }\n+      themeListener.unsubscribe(this.context, this.subscriptionId);\n     }\n     ```\n+* `themeListener.unsubscribe`\n+  * type: `Function`\n+  * takes 2 arguments:\n+    * context `Object`, where `context` is `this.context` from your component\n+    * subscriptionId `Number` returned by `themeListener.subscribe` in `componentDidMount`\n+  * meant to be used in `componentWillUnmount`\n+  * returns nothing\n+  * example:\n+    ```js\n+    componentDidMount() {\n+      this.subscriptionId = themeListener.subscribe(this.context, theme => this.setState({ theme }));\n+    }\n+    componentWillUnmount() {\n+      themeListener.unsubscribe(this.context, this.subscriptionId);\n+    }\n+    ```\n+    ```","path":"README.md","position":50,"original_position":50,"commit_id":"2925fb3f9289765e76703a33c093d4a125975489","original_commit_id":"2925fb3f9289765e76703a33c093d4a125975489","user":{"login":"kof","id":52824,"avatar_url":"https://avatars0.githubusercontent.com/u/52824?v=4","gravatar_id":"","url":"https://api.github.com/users/kof","html_url":"https://github.com/kof","followers_url":"https://api.github.com/users/kof/followers","following_url":"https://api.github.com/users/kof/following{/other_user}","gists_url":"https://api.github.com/users/kof/gists{/gist_id}","starred_url":"https://api.github.com/users/kof/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kof/subscriptions","organizations_url":"https://api.github.com/users/kof/orgs","repos_url":"https://api.github.com/users/kof/repos","events_url":"https://api.github.com/users/kof/events{/privacy}","received_events_url":"https://api.github.com/users/kof/received_events","type":"User","site_admin":false},"body":"shouldn't be there, righT?","created_at":"2017-10-14T11:46:48Z","updated_at":"2017-10-14T11:46:48Z","html_url":"https://github.com/cssinjs/theming/pull/38#discussion_r144692579","pull_request_url":"https://api.github.com/repos/cssinjs/theming/pulls/38","author_association":"OWNER","_links":{"self":{"href":"https://api.github.com/repos/cssinjs/theming/pulls/comments/144692579"},"html":{"href":"https://github.com/cssinjs/theming/pull/38#discussion_r144692579"},"pull_request":{"href":"https://api.github.com/repos/cssinjs/theming/pulls/38"}}},"pull_request":{"url":"https://api.github.com/repos/cssinjs/theming/pulls/38","id":141069006,"html_url":"https://github.com/cssinjs/theming/pull/38","diff_url":"https://github.com/cssinjs/theming/pull/38.diff","patch_url":"https://github.com/cssinjs/theming/pull/38.patch","issue_url":"https://api.github.com/repos/cssinjs/theming/issues/38","number":38,"state":"open","locked":false,"title":"Update brcast to ^3.0.1","user":{"login":"darkowic","id":11510581,"avatar_url":"https://avatars2.githubusercontent.com/u/11510581?v=4","gravatar_id":"","url":"https://api.github.com/users/darkowic","html_url":"https://github.com/darkowic","followers_url":"https://api.github.com/users/darkowic/followers","following_url":"https://api.github.com/users/darkowic/following{/other_user}","gists_url":"https://api.github.com/users/darkowic/gists{/gist_id}","starred_url":"https://api.github.com/users/darkowic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/darkowic/subscriptions","organizations_url":"https://api.github.com/users/darkowic/orgs","repos_url":"https://api.github.com/users/darkowic/repos","events_url":"https://api.github.com/users/darkowic/events{/privacy}","received_events_url":"https://api.github.com/users/darkowic/received_events","type":"User","site_admin":false},"body":"BREAKING CHANGE: themeListener.subscribe returns subscriptionId intead of function. To unsubscribe you have to call themeListener.unsubscribe(subscriptionId)\r\n\r\nResolves #36 ","created_at":"2017-09-14T13:04:57Z","updated_at":"2017-10-14T11:46:48Z","closed_at":null,"merged_at":null,"merge_commit_sha":"114cb6a91d224670170dc8fea549e77cba3208e5","assignee":null,"assignees":[],"requested_reviewers":[],"milestone":null,"commits_url":"https://api.github.com/repos/cssinjs/theming/pulls/38/commits","review_comments_url":"https://api.github.com/repos/cssinjs/theming/pulls/38/comments","review_comment_url":"https://api.github.com/repos/cssinjs/theming/pulls/comments{/number}","comments_url":"https://api.github.com/repos/cssinjs/theming/issues/38/comments","statuses_url":"https://api.github.com/repos/cssinjs/theming/statuses/2925fb3f9289765e76703a33c093d4a125975489","head":{"label":"darkowic:master","ref":"master","sha":"2925fb3f9289765e76703a33c093d4a125975489","user":{"login":"darkowic","id":11510581,"avatar_url":"https://avatars2.githubusercontent.com/u/11510581?v=4","gravatar_id":"","url":"https://api.github.com/users/darkowic","html_url":"https://github.com/darkowic","followers_url":"https://api.github.com/users/darkowic/followers","following_url":"https://api.github.com/users/darkowic/following{/other_user}","gists_url":"https://api.github.com/users/darkowic/gists{/gist_id}","starred_url":"https://api.github.com/users/darkowic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/darkowic/subscriptions","organizations_url":"https://api.github.com/users/darkowic/orgs","repos_url":"https://api.github.com/users/darkowic/repos","events_url":"https://api.github.com/users/darkowic/events{/privacy}","received_events_url":"https://api.github.com/users/darkowic/received_events","type":"User","site_admin":false},"repo":{"id":103521839,"name":"theming","full_name":"darkowic/theming","owner":{"login":"darkowic","id":11510581,"avatar_url":"https://avatars2.githubusercontent.com/u/11510581?v=4","gravatar_id":"","url":"https://api.github.com/users/darkowic","html_url":"https://github.com/darkowic","followers_url":"https://api.github.com/users/darkowic/followers","following_url":"https://api.github.com/users/darkowic/following{/other_user}","gists_url":"https://api.github.com/users/darkowic/gists{/gist_id}","starred_url":"https://api.github.com/users/darkowic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/darkowic/subscriptions","organizations_url":"https://api.github.com/users/darkowic/orgs","repos_url":"https://api.github.com/users/darkowic/repos","events_url":"https://api.github.com/users/darkowic/events{/privacy}","received_events_url":"https://api.github.com/users/darkowic/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/darkowic/theming","description":"Unified CSSinJS theming solution for React","fork":true,"url":"https://api.github.com/repos/darkowic/theming","forks_url":"https://api.github.com/repos/darkowic/theming/forks","keys_url":"https://api.github.com/repos/darkowic/theming/keys{/key_id}","collaborators_url":"https://api.github.com/repos/darkowic/theming/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/darkowic/theming/teams","hooks_url":"https://api.github.com/repos/darkowic/theming/hooks","issue_events_url":"https://api.github.com/repos/darkowic/theming/issues/events{/number}","events_url":"https://api.github.com/repos/darkowic/theming/events","assignees_url":"https://api.github.com/repos/darkowic/theming/assignees{/user}","branches_url":"https://api.github.com/repos/darkowic/theming/branches{/branch}","tags_url":"https://api.github.com/repos/darkowic/theming/tags","blobs_url":"https://api.github.com/repos/darkowic/theming/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/darkowic/theming/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/darkowic/theming/git/refs{/sha}","trees_url":"https://api.github.com/repos/darkowic/theming/git/trees{/sha}","statuses_url":"https://api.github.com/repos/darkowic/theming/statuses/{sha}","languages_url":"https://api.github.com/repos/darkowic/theming/languages","stargazers_url":"https://api.github.com/repos/darkowic/theming/stargazers","contributors_url":"https://api.github.com/repos/darkowic/theming/contributors","subscribers_url":"https://api.github.com/repos/darkowic/theming/subscribers","subscription_url":"https://api.github.com/repos/darkowic/theming/subscription","commits_url":"https://api.github.com/repos/darkowic/theming/commits{/sha}","git_commits_url":"https://api.github.com/repos/darkowic/theming/git/commits{/sha}","comments_url":"https://api.github.com/repos/darkowic/theming/comments{/number}","issue_comment_url":"https://api.github.com/repos/darkowic/theming/issues/comments{/number}","contents_url":"https://api.github.com/repos/darkowic/theming/contents/{+path}","compare_url":"https://api.github.com/repos/darkowic/theming/compare/{base}...{head}","merges_url":"https://api.github.com/repos/darkowic/theming/merges","archive_url":"https://api.github.com/repos/darkowic/theming/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/darkowic/theming/downloads","issues_url":"https://api.github.com/repos/darkowic/theming/issues{/number}","pulls_url":"https://api.github.com/repos/darkowic/theming/pulls{/number}","milestones_url":"https://api.github.com/repos/darkowic/theming/milestones{/number}","notifications_url":"https://api.github.com/repos/darkowic/theming/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/darkowic/theming/labels{/name}","releases_url":"https://api.github.com/repos/darkowic/theming/releases{/id}","deployments_url":"https://api.github.com/repos/darkowic/theming/deployments","created_at":"2017-09-14T10:59:55Z","updated_at":"2017-09-14T10:59:56Z","pushed_at":"2017-09-14T13:02:46Z","git_url":"git://github.com/darkowic/theming.git","ssh_url":"git@github.com:darkowic/theming.git","clone_url":"https://github.com/darkowic/theming.git","svn_url":"https://github.com/darkowic/theming","homepage":"","size":124,"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,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"cssinjs:master","ref":"master","sha":"ded45451c856ecd05ed4fc2cf4f6044bd916c323","user":{"login":"cssinjs","id":9503099,"avatar_url":"https://avatars0.githubusercontent.com/u/9503099?v=4","gravatar_id":"","url":"https://api.github.com/users/cssinjs","html_url":"https://github.com/cssinjs","followers_url":"https://api.github.com/users/cssinjs/followers","following_url":"https://api.github.com/users/cssinjs/following{/other_user}","gists_url":"https://api.github.com/users/cssinjs/gists{/gist_id}","starred_url":"https://api.github.com/users/cssinjs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cssinjs/subscriptions","organizations_url":"https://api.github.com/users/cssinjs/orgs","repos_url":"https://api.github.com/users/cssinjs/repos","events_url":"https://api.github.com/users/cssinjs/events{/privacy}","received_events_url":"https://api.github.com/users/cssinjs/received_events","type":"Organization","site_admin":false},"repo":{"id":89290601,"name":"theming","full_name":"cssinjs/theming","owner":{"login":"cssinjs","id":9503099,"avatar_url":"https://avatars0.githubusercontent.com/u/9503099?v=4","gravatar_id":"","url":"https://api.github.com/users/cssinjs","html_url":"https://github.com/cssinjs","followers_url":"https://api.github.com/users/cssinjs/followers","following_url":"https://api.github.com/users/cssinjs/following{/other_user}","gists_url":"https://api.github.com/users/cssinjs/gists{/gist_id}","starred_url":"https://api.github.com/users/cssinjs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cssinjs/subscriptions","organizations_url":"https://api.github.com/users/cssinjs/orgs","repos_url":"https://api.github.com/users/cssinjs/repos","events_url":"https://api.github.com/users/cssinjs/events{/privacy}","received_events_url":"https://api.github.com/users/cssinjs/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/cssinjs/theming","description":"Unified CSSinJS theming solution for React","fork":false,"url":"https://api.github.com/repos/cssinjs/theming","forks_url":"https://api.github.com/repos/cssinjs/theming/forks","keys_url":"https://api.github.com/repos/cssinjs/theming/keys{/key_id}","collaborators_url":"https://api.github.com/repos/cssinjs/theming/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/cssinjs/theming/teams","hooks_url":"https://api.github.com/repos/cssinjs/theming/hooks","issue_events_url":"https://api.github.com/repos/cssinjs/theming/issues/events{/number}","events_url":"https://api.github.com/repos/cssinjs/theming/events","assignees_url":"https://api.github.com/repos/cssinjs/theming/assignees{/user}","branches_url":"https://api.github.com/repos/cssinjs/theming/branches{/branch}","tags_url":"https://api.github.com/repos/cssinjs/theming/tags","blobs_url":"https://api.github.com/repos/cssinjs/theming/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/cssinjs/theming/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/cssinjs/theming/git/refs{/sha}","trees_url":"https://api.github.com/repos/cssinjs/theming/git/trees{/sha}","statuses_url":"https://api.github.com/repos/cssinjs/theming/statuses/{sha}","languages_url":"https://api.github.com/repos/cssinjs/theming/languages","stargazers_url":"https://api.github.com/repos/cssinjs/theming/stargazers","contributors_url":"https://api.github.com/repos/cssinjs/theming/contributors","subscribers_url":"https://api.github.com/repos/cssinjs/theming/subscribers","subscription_url":"https://api.github.com/repos/cssinjs/theming/subscription","commits_url":"https://api.github.com/repos/cssinjs/theming/commits{/sha}","git_commits_url":"https://api.github.com/repos/cssinjs/theming/git/commits{/sha}","comments_url":"https://api.github.com/repos/cssinjs/theming/comments{/number}","issue_comment_url":"https://api.github.com/repos/cssinjs/theming/issues/comments{/number}","contents_url":"https://api.github.com/repos/cssinjs/theming/contents/{+path}","compare_url":"https://api.github.com/repos/cssinjs/theming/compare/{base}...{head}","merges_url":"https://api.github.com/repos/cssinjs/theming/merges","archive_url":"https://api.github.com/repos/cssinjs/theming/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/cssinjs/theming/downloads","issues_url":"https://api.github.com/repos/cssinjs/theming/issues{/number}","pulls_url":"https://api.github.com/repos/cssinjs/theming/pulls{/number}","milestones_url":"https://api.github.com/repos/cssinjs/theming/milestones{/number}","notifications_url":"https://api.github.com/repos/cssinjs/theming/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/cssinjs/theming/labels{/name}","releases_url":"https://api.github.com/repos/cssinjs/theming/releases{/id}","deployments_url":"https://api.github.com/repos/cssinjs/theming/deployments","created_at":"2017-04-24T21:53:51Z","updated_at":"2017-10-14T11:29:49Z","pushed_at":"2017-10-03T15:26:36Z","git_url":"git://github.com/cssinjs/theming.git","ssh_url":"git@github.com:cssinjs/theming.git","clone_url":"https://github.com/cssinjs/theming.git","svn_url":"https://github.com/cssinjs/theming","homepage":"","size":127,"stargazers_count":152,"watchers_count":152,"language":"JavaScript","has_issues":true,"has_projects":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":14,"mirror_url":null,"open_issues_count":25,"forks":14,"open_issues":25,"watchers":152,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/cssinjs/theming/pulls/38"},"html":{"href":"https://github.com/cssinjs/theming/pull/38"},"issue":{"href":"https://api.github.com/repos/cssinjs/theming/issues/38"},"comments":{"href":"https://api.github.com/repos/cssinjs/theming/issues/38/comments"},"review_comments":{"href":"https://api.github.com/repos/cssinjs/theming/pulls/38/comments"},"review_comment":{"href":"https://api.github.com/repos/cssinjs/theming/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/cssinjs/theming/pulls/38/commits"},"statuses":{"href":"https://api.github.com/repos/cssinjs/theming/statuses/2925fb3f9289765e76703a33c093d4a125975489"}},"author_association":"NONE"}}
{"actor":{"display_login":"kof"}}