correct typo in javascript