Finished cleaning up some of the JS for the Web UI