prevents javascript error