Allow removal of domain names
Add tests for different cases