Index: trunk/phase3/RELEASE-NOTES-1.19 |
— | — | @@ -189,6 +189,8 @@ |
190 | 190 | causes the first log type requested to be removed but not the others |
191 | 191 | * Use separate message ('prefixindex-namespace') for title of |
192 | 192 | Special:PrefixIndex rather then re-using Special:AllPages's allinnamespace |
| 193 | +* (bug 33156) Special:Block now allows you to confirm you want to block yourself |
| 194 | + when using non-normalized username |
193 | 195 | |
194 | 196 | === API changes in 1.19 === |
195 | 197 | * (bug 19838) siprop=interwikimap can now use the interwiki cache. |
Index: trunk/phase3/includes/specials/SpecialBlock.php |
— | — | @@ -565,9 +565,13 @@ |
566 | 566 | |
567 | 567 | # Give admins a heads-up before they go and block themselves. Much messier |
568 | 568 | # to do this for IPs, but it's pretty unlikely they'd ever get the 'block' |
569 | | - # permission anyway, although the code does allow for it |
| 569 | + # permission anyway, although the code does allow for it. |
| 570 | + # Note: Important to use $target instead of $data['Target'] |
| 571 | + # since both $data['PreviousTarget'] and $target are normalized |
| 572 | + # but $data['target'] gets overriden by (non-normalized) request variable |
| 573 | + # from previous request. |
570 | 574 | if( $target === $performer->getName() && |
571 | | - ( $data['PreviousTarget'] !== $data['Target'] || !$data['Confirm'] ) ) |
| 575 | + ( $data['PreviousTarget'] !== $target || !$data['Confirm'] ) ) |
572 | 576 | { |
573 | 577 | return array( 'ipb-blockingself' ); |
574 | 578 | } |