Merge "drop "@fixed" annotations in CologneBlue skin"
[lhc/web/wiklou.git] / includes / api / ApiQueryBlocks.php
index d88e4da..7cc1755 100644 (file)
@@ -182,8 +182,8 @@ class ApiQueryBlocks extends ApiQueryBase {
                                $block['reason'] = $row->ipb_reason;
                        }
                        if ( $fld_range && !$row->ipb_auto ) {
-                               $block['rangestart'] = IP::hexToQuad( $row->ipb_range_start );
-                               $block['rangeend'] = IP::hexToQuad( $row->ipb_range_end );
+                               $block['rangestart'] = IP::formatHex( $row->ipb_range_start );
+                               $block['rangeend'] = IP::formatHex( $row->ipb_range_end );
                        }
                        if ( $fld_flags ) {
                                // For clarity, these flags use the same names as their action=block counterparts
@@ -301,7 +301,7 @@ class ApiQueryBlocks extends ApiQueryBase {
                        'dir' => $this->getDirectionDescription( $p ),
                        'ids' => 'List of block IDs to list (optional)',
                        'users' => 'List of users to search for (optional)',
-                       'ip' => array(  'Get all blocks applying to this IP or CIDR range, including range blocks.',
+                       'ip' => array( 'Get all blocks applying to this IP or CIDR range, including range blocks.',
                                        'Cannot be used together with bkusers. CIDR ranges broader than /16 are not accepted' ),
                        'limit' => 'The maximum amount of blocks to list',
                        'prop' => array(
@@ -383,13 +383,15 @@ class ApiQueryBlocks extends ApiQueryBase {
        }
 
        public function getPossibleErrors() {
-               return array_merge( parent::getPossibleErrors(), array(
+               return array_merge( parent::getPossibleErrors(),
                        $this->getRequireOnlyOneParameterErrorMessages( array( 'users', 'ip' ) ),
-                       array( 'code' => 'cidrtoobroad', 'info' => 'CIDR ranges broader than /16 are not accepted' ),
-                       array( 'code' => 'param_user', 'info' => 'User parameter may not be empty' ),
-                       array( 'code' => 'param_user', 'info' => 'User name user is not valid' ),
-                       array( 'show' ),
-               ) );
+                       array(
+                               array( 'code' => 'cidrtoobroad', 'info' => 'CIDR ranges broader than /16 are not accepted' ),
+                               array( 'code' => 'param_user', 'info' => 'User parameter may not be empty' ),
+                               array( 'code' => 'param_user', 'info' => 'User name user is not valid' ),
+                               array( 'show' ),
+                       )
+               );
        }
 
        public function getExamples() {