fixed typo in js code