typo fix and js bugfix