{"action":"opened","issue":{"url":"https://api.github.com/repos/minhtranite/react-photoswipe/issues/16","repository_url":"https://api.github.com/repos/minhtranite/react-photoswipe","labels_url":"https://api.github.com/repos/minhtranite/react-photoswipe/issues/16/labels{/name}","comments_url":"https://api.github.com/repos/minhtranite/react-photoswipe/issues/16/comments","events_url":"https://api.github.com/repos/minhtranite/react-photoswipe/issues/16/events","html_url":"https://github.com/minhtranite/react-photoswipe/issues/16","id":182342155,"number":16,"title":"this.setState in the onClose","user":{"login":"mbeauchamp7","id":15185355,"avatar_url":"https://avatars.githubusercontent.com/u/15185355?v=3","gravatar_id":"","url":"https://api.github.com/users/mbeauchamp7","html_url":"https://github.com/mbeauchamp7","followers_url":"https://api.github.com/users/mbeauchamp7/followers","following_url":"https://api.github.com/users/mbeauchamp7/following{/other_user}","gists_url":"https://api.github.com/users/mbeauchamp7/gists{/gist_id}","starred_url":"https://api.github.com/users/mbeauchamp7/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mbeauchamp7/subscriptions","organizations_url":"https://api.github.com/users/mbeauchamp7/orgs","repos_url":"https://api.github.com/users/mbeauchamp7/repos","events_url":"https://api.github.com/users/mbeauchamp7/events{/privacy}","received_events_url":"https://api.github.com/users/mbeauchamp7/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2016-10-11T18:43:56Z","updated_at":"2016-10-11T18:43:56Z","closed_at":null,"body":"Hi,\r\n\r\nI was testing the PhotoSwipe component in my app and everything was working fine until I was zoomed and tried to logout(change route) and got a warning about setting the state on an unmounted component.\r\n\r\nSo I looked in the source and found that isOpen is actually handled on it's own in the state of the component and set to false when being closed.\r\n[Here](https://github.com/minhtranite/react-photoswipe/blob/master/src/PhotoSwipe.js#L93-L102)\r\n\r\nI was wondering if there would be a way to override the isOpen with the actual props? It would be much better this way I think.\r\n\r\nThanks!"}}
{"actor":{"display_login":"mbeauchamp7"}}