Page MenuHomePhabricator

Fatal error: Call to a member function getEntityType() on a non-object
Closed, ResolvedPublic

Description

Lowercase prefixed ids, such as q2454 work just fine but you get a fatal error if you request an entity with an uppercase prefix in wbgetentities:

Fatal error: Call to a member function getEntityType() on a non-object in /var/www/wikidata-test-repo.wikimedia.de/w/extensions/Wikibase/repo/includes/api/ApiGetEntities.php on line 107

http://wikidata-test-repo.wikimedia.de/w/api.php?action=wbgetentities&ids=Q2454&format=json

We ought to be nicer and I think allow uppercase prefix.

At very minimum show a nicer error and tells the api user to provide a lowercase prefix, but don't think that's a very nice solution and would prefer we not be case insensitive here.


Version: master
Severity: major

Details

Reference
bz42176