fix passing instance to .dom file