fix NULL exception for IE