Fix error with removing formats in IE