{"action":"opened","issue":{"url":"https://api.github.com/repos/ChemistryMike/jammming/issues/3","repository_url":"https://api.github.com/repos/ChemistryMike/jammming","labels_url":"https://api.github.com/repos/ChemistryMike/jammming/issues/3/labels{/name}","comments_url":"https://api.github.com/repos/ChemistryMike/jammming/issues/3/comments","events_url":"https://api.github.com/repos/ChemistryMike/jammming/issues/3/events","html_url":"https://github.com/ChemistryMike/jammming/issues/3","id":297971626,"number":3,"title":"Adding tracks to playlist","user":{"login":"stevetoro","id":7355203,"avatar_url":"https://avatars1.githubusercontent.com/u/7355203?v=4","gravatar_id":"","url":"https://api.github.com/users/stevetoro","html_url":"https://github.com/stevetoro","followers_url":"https://api.github.com/users/stevetoro/followers","following_url":"https://api.github.com/users/stevetoro/following{/other_user}","gists_url":"https://api.github.com/users/stevetoro/gists{/gist_id}","starred_url":"https://api.github.com/users/stevetoro/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stevetoro/subscriptions","organizations_url":"https://api.github.com/users/stevetoro/orgs","repos_url":"https://api.github.com/users/stevetoro/repos","events_url":"https://api.github.com/users/stevetoro/events{/privacy}","received_events_url":"https://api.github.com/users/stevetoro/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-02-17T02:37:03Z","updated_at":"2018-02-17T02:37:03Z","closed_at":null,"author_association":"NONE","body":"https://github.com/ChemistryMike/jammming/blob/master/src/Components/App/App.js#L23-L31\r\n\r\n`.includes` will not always behave as you expect it to. To see why, add a track to a playlist, then run a different search, and try to add the same track to the playlist again. You'll be able to add it without issue, because `.includes` is only checking for the _exact same object_, which is not the case in between searches.\r\n\r\nConsider using an array iterator like `.some()` or `.find()` to validate whether a track should be added to a playlist or not by comparing its track ID to the track ID of every track currently in the playlist."}}
{"actor":{"display_login":"stevetoro"}}