Revert "fixed some js bugs"

This reverts commit 84e1e987b231254b36b8ec4f754ea254d9a6c3bd.