fixed the incorrect js at the end of file