Fix js error