fixing js errors in ready.vm