cleaned up dom library