Add callback to loadDomain to make it easier to use