Learn localStorage by Building a Todo App - Step 46

Tell us what’s happening:

Tests are failing with the following:

Your formInputValuesUpdated variable should check if titleInput.value is not equal to currentTask.title.

But, I am doing what the test says I am not doing. My guess, again, is there is a formatting problem I don’t see, I am not a javascript formatting expert and Visual Studio Code is happy with my formatting. The code does work, I have a local copy I make as I go along.

### Your code so far

Current code:

const formInputValuesUpdated = titleInput.value != currentTask.title || dateInput.value != currentTask.date || descriptionInput.value != currentTask.description;

Also doesn’t work, gives the same failure. It’s also wrong using the &&, the user would have to change all 3 inputs instead of one.

const formInputValuesUpdated = titleInput.value != currentTask.title && dateInput.value != currentTask.date && descriptionInput.value != currentTask.description;

Also doesn’t work.

const formInputValuesUpdated = titleInput.value !== currentTask.title || dateInput.value !== currentTask.date || descriptionInput.value !== currentTask.description;

Your browser information:

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

Challenge Information:

Learn localStorage by Building a Todo App - Step 46

this passes for me, are you sure you have not changed things outside the editable region?

1 Like

Thanks. Wasn’t working for me until I ctrl+f5 a few hours ago to refresh the page from the server. My guess is someone fixed it.

Mine worked using !== instead of != as the “not-equal” operator

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.