js error fixed