Fix bugs + js