Thank you so much for finding that and pointing it out. I've corrected the example. Ironically, you kind of illustrated how easy it is to make a mistake in JS because I wrote that example without VSCode's help. If I had written that example in TypeScript I wouldn't have been able to make the mistake.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Wait, shouldn't the check
if(newUserToSave.lastName)
be
if(!newUserToSave.lastName)
? :D
Thank you so much for finding that and pointing it out. I've corrected the example. Ironically, you kind of illustrated how easy it is to make a mistake in JS because I wrote that example without VSCode's help. If I had written that example in TypeScript I wouldn't have been able to make the mistake.