correctly return empty string for domain ID if it is null