[QuickStatements] changing or editing Property labels, descriptions and aliases fails

Issue #112 resolved
Frog23 created an issue

It is currently not possible to use QS to edit the labels, descriptions or aliases of a property, while it is possible to do this using the API.

After going through the code (on my local installation) I found that the issue is the call

'id' => $this->getPrefixedID ( $command->item ) ,

in quickstatements.php in the functions commandSetLabe, (line 896), commandSetDescription (line 936) and commandAddAlias (line 919). The API expects the ID to have the form of "P1234" and not of "Property:P1234" which what it is transformed into.
Replacing these lines against

'id' => $command->item ,

fixes the issue.

(Note the call is also used in commandSetSitelink (line 954) but since Properties don't have site links, it doesn't matter there, but should be removed as well as it doesn't do anything. This would then make the entire function getPrefixedID obsolete as it is not used anymore.)

Comments (2)

  1. Log in to comment