Learn Basic String and Array Methods by Building a Music Player - Step 87

Tell us what’s happening:

For some reason I enter the exact same thing as the hint is trying to help me, and i also tried doing the userData to it’s original object, but nothing seems to work

Your code so far

<!-- file: index.html -->

/* file: script.js */
// User Editable Region

  if(userData?.songs.length === 0)
  {
     userData = {
      songs: [...allSongs],
      currentSong: null,
      songCurrentTime: 0,
    };
  }

// User Editable Region
/* file: styles.css */

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/133.0.0.0 Safari/537.36

Challenge Information:

Learn Basic String and Array Methods by Building a Music Player - Step 87

Hi there and welcome to our community!

Your if condition should be empty in this step. You should have only the condition and an empty set of curly brackets.