Fixed a few more JS errors