The introduction of RepoEntityChange and RepoItemChange led to the problem outlined in the parent task. The code within RepoEntityChange does not need to live in a subclass of EntityChange so we can get rid of it as it may lead to confusion again in the future.
Planned steps:
- Extract RecentChangeSaveHookHandler as the future home for RepoEntityChange::setMetadataFromRC - https://gerrit.wikimedia.org/r/c/689946
- Move RepoEntityChange::setMetadataFromRC to RecentChangeSaveHookHandle - https://gerrit.wikimedia.org/r/c/mediawiki/extensions/Wikibase/+/691130
- Move RepoEntityChange::setMetadataFromUser and RepoEntityChange::setRevisionInfo to ChangeNotifier - https://gerrit.wikimedia.org/r/c/mediawiki/extensions/Wikibase/+/691195
- Actually remove RepoEntityChange and friends - https://gerrit.wikimedia.org/r/c/mediawiki/extensions/Wikibase/+/691202
- Refactor ChangeNotifier. It was a big complicated class before, and after step 2 it'll be even worse. - https://gerrit.wikimedia.org/r/c/mediawiki/extensions/Wikibase/+/692903