fixed js syntax issue