though if you just move the get_domain function to a helper in hq land then the rest of this looks like it won't break...