Better domain handling