Bugfix for IE 11 failing to getdocument.