Page MenuHomePhabricator

PHP warnings when global-renaming users in SQLite
Closed, ResolvedPublicBUG REPORT

Description

Steps to replicate the issue (include links if applicable):
On a wiki using SQLite and CentralAuth:

  • Open Special:GlobalRenameUser
  • Enter information to rename any account

What happens?:
Two PHP warnings:

Warning: Attempt to read property "ru_wiki" on array in /var/www/html/w/extensions/CentralAuth/includes/GlobalRename/GlobalRenameUserStatus.php on line 176

Warning: Attempt to read property "ru_oldname" on array in /var/www/html/w/extensions/CentralAuth/includes/GlobalRename/GlobalRenameUserStatus.php on line 177

What should have happened instead?:
No warnings.

Other information (browser name/version, screenshots, etc.):
This happens for SQLite and presumably also postgres but not MySQL, as the relevant code is behind a dbtype === mysql conditional.

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald Transcript

Change #1196095 had a related patch set uploaded (by Daimona Eaytoy; author: Daimona Eaytoy):

[mediawiki/extensions/CentralAuth@master] Avoid PHP warning due to treating an array as stdClass

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

Change #1196095 merged by jenkins-bot:

[mediawiki/extensions/CentralAuth@master] Avoid PHP warning due to treating an array as stdClass

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