Page MenuHomePhabricator

🏷️ Handle label not found for item
Closed, ResolvedPublic

Description

if there is no label for the given language, throw a UseCaseError with a new errorCode LABEL_NOT_DEFINED
generate a 404 response from the error
{

"code": "label-not-defined",
"message": "Item with the ID {item_id} does not have a label in the language: {language_code}"

}

Event Timeline

Change 901560 had a related patch set uploaded (by Jakob; author: Jakob):

[mediawiki/extensions/Wikibase@master] REST: Respond with 404 if requested label does not exist

https://gerrit.wikimedia.org/r/901560

Change 901560 merged by jenkins-bot:

[mediawiki/extensions/Wikibase@master] REST: Respond with 404 if requested label does not exist

https://gerrit.wikimedia.org/r/901560