Moved JS to the right place