When enabling taxonomy terms, existing terms are not being correctly assigned to domains and become invisible until you disable the access again.
The cause is:
$query->fieldCondition($field_name, 'domain_id', NULL);
Which is making the EntityFieldQuery return no results and therefore the $unaffiliated_entries array is empty.
A quick fix is to comment out this line (735 of domain_entity.module)
Comments
Comment #2
bohartD7 reached its EOL back in January 2025, and there is no active release for D7 for this module.
Neither development nor support is planned for D7.
All D7-related issues (especially those with ~10 years of inactivity) are marked as outdated in a bunch.
If/once the issue still arises in D11+ versions, please create a follow-up issue.
Thanks!