fixing js screwup