cleaning up some of the js