Learn JavaScript Algorithm and Data structure by Building A Music Player - Step 38

https://www.freecodecamp.org/learn/javascript-algorithms-and-data-structures-v8/#learn-basic-string-and-array-methods-by-building-a-music-player-step 38.
please assist what I should do because my console generates this error at this step;
SyntaxError: unknown: Support for the experimental syntax ‘optionalChainingAssign’ isn’t currently enabled (93:4):

1 Like

from the error you are using the optional chaining operator ? in the wrong place

Please post your code here to receive help

1 Like

here is my code;
if(userData?.currentSong=null || userData?.currentSong.id!==song.id){

in there there is an assigment operator when there should be a comparison. check carefully and change it

thanks, just noticed the correct operator .error has been cleared.