js errro fixed