update the js for logging