Problem/Motivation

DisplayBuilderEntityViewHook::entityDelete() removes the override instance when its entity is deleted, but nothing reacts to a single translation being deleted. The instance keeps that language's data, and it comes back as stale content if the translation is added again later.

Proposed resolution

  • Implement hook_entity_translation_delete(): remove the matching translation from the override instance.
  • Kernel test: delete a node translation, assert the instance no longer has it.
  • While there, cover a node whose default language differs from the site default language, which no test exercises today.

Comments

mogtofu33 created an issue. See original summary.