fix js errors per tests