Page MenuHomePhabricator

Allow EntityContent to be constructed completely empty, with no Entity inside.
Closed, ResolvedPublic


MediaWiki core currently requires the ability to construct empty Content objects for any content model, via ContentHandler::makeEmptyContent. To support this even for kinds of entities that cannot be completely empty (like Properties and Lexemes), we need to allow EntityContent to be created with no Entity object.

Note that EntityContent can already exist with no Entity attached - in case the EntityContent is a redirect. This task asks for the ability to create EntityContent objects that are not redirects and do not contain an Entity.

Event Timeline

Change 356239 had a related patch set uploaded (by Daniel Kinzler; owner: Thiemo Mättig (WMDE)):
[mediawiki/extensions/Wikibase@master] [WIP] Allow EntityContent to contain no EntityHolder

Change 356239 merged by jenkins-bot:
[mediawiki/extensions/Wikibase@master] Fix two EntityContent methods not considering empty EntityHolders

daniel claimed this task.