Last modified: 2014-02-12 23:32:50 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 T50546, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 48546 - Hooks on blocking, but not for unblocking.
Hooks on blocking, but not for unblocking.
Status: UNCONFIRMED
Product: MediaWiki
Classification: Unclassified
User blocking (Other open bugs)
1.20.x
All All
: Low enhancement (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2013-05-16 17:45 UTC by Alexia E. Smith
Modified: 2014-02-12 23:32 UTC (History)
1 user (show)

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


Attachments

Description Alexia E. Smith 2013-05-16 17:45:45 UTC
Currently there are two hooks for when a user is blocked in SpecialBlock, BlockIp and BlockIpComplete, but none for unblocking a user in SpecialUnblock.  So if an extension needs to reliably add and remove information about user blocks that extension will never be able to hook in to see when a user block is removed through SpecialUnblock.

At a minimum a similar UnblockIpComplete hook would be ideal.
Comment 1 Alex Monk 2013-05-18 20:49:07 UTC
Were you hoping to be able to use this hook in any particular extension?
What parameters does it need? Just performer, target and reason?
Comment 2 Alexia E. Smith 2013-05-21 17:21:26 UTC
I planned to use this in an authentication extension that obeys blocking rules.  This could be useful in the OpenID extension and other people that need to spreading blocking rules across wiki farms.

Passing in $performer and $block should be ideal.  The $block contains the target and other relevant data.  I believe the new unblock reason would have to be passed in since the existing $block would contain the original reason for blocking.

Sample documentation:
'UnblockIpComplete': after an IP address or user is unblocked
$performer: The user performing the unblock
$block: The Block object that was modified or deleted
$reason: The new reason to unblocking the block target.

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


Navigation
Links