thelinmichael/spotify-web-api-node

trackIds.join is not a function - containsMySavedTracks

Noelg14 opened this issue · 1 comments

When calling the function containsMySavedTracks I am getting the following Exception:

(node:8748) UnhandledPromiseRejectionWarning: TypeError: trackIds.join is not a function
    at SpotifyWebApi.containsMySavedTracks (\node_modules\spotify-web-api-node\src\spotify-web-api.js:804:23) 

This function called using the track URI

//@param song is track uri from getCurrentTrack
//
function isLiked(song){
  spotifyApi.containsMySavedTracks(song)
  .then(result =>{
     console.log(result)
     return result;
  }) .catch(err =>{
    console.log(err)
  })
}

argument of containsMySavedTracks should be an array