Last modified: 2013-01-18 18:24:26 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T44228, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 42228 - Login error message for blacklisted user autocreation shows markup
Login error message for blacklisted user autocreation shows markup
Status: RESOLVED DUPLICATE of bug 38894
Product: MediaWiki extensions
Classification: Unclassified
TitleBlacklist (Other open bugs)
unspecified
All All
: Normal minor (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks: messages
  Show dependency treegraph
 
Reported: 2012-11-17 12:54 UTC by Mormegil
Modified: 2013-01-18 18:24 UTC (History)
4 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments
Screenshot of a broken error message (83.40 KB, image/jpeg)
2012-11-17 12:54 UTC, Mormegil
Details

Description Mormegil 2012-11-17 12:54:24 UTC
Created attachment 11387 [details]
Screenshot of a broken error message

When TitleBlacklist blocks creation of a new user account, the error message is now correctly parsed and displayed (see bug 41242). However, if it blocks autocreation of a local user account, the message is broken. See the attached screenshot.

The problem is that while the AbortNewAccount hook (see http://www.mediawiki.org/wiki/Manual:Hooks/AbortNewAccount) returns the error _message text_, the AbortAutoAccount hook (http://www.mediawiki.org/wiki/Manual:Hooks/AbortAutoAccount) returns the error _message name_. But both hooks are implemented with TitleBlacklistHooks::abortNewAccount which currently returns the error message text, so that AbortNewAccount works, while AbortAutoAccount does not. (Note the extra angle brackets on the screenshot: the resulting _message_ is used as a message name.)

The simple solution of separating the hook implementation into a new abortAutoAccount method and leaving the wfMessage call just in abortNewAccount is probably not acceptable, because AbortAutoAccount would result in a message without the $1 and $2 parameters. Either a new nonspecific parameterless message would need to be used in this case or the whole AbortNewAccount hook would need to be redesigned.
Comment 1 Andre Klapper 2013-01-18 18:24:26 UTC
Thanks for taking the time to report this!

That string is https://en.wikipedia.org/wiki/MediaWiki:Titleblacklist-forbidden-new-account and hence a duplicate of bug 38894.

*** This bug has been marked as a duplicate of bug 38894 ***

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links