fix the js error