fixing js error

fixing js error