Queries like the following return wrong rangestart and rangeend
data cause the IP addresses are formated with only IPv4 in mind.
As IP::formatHex is able to format both I've switched over to
that.
Example:
http://en.wikipedia.org/w/api.php?format=xml&action=query&list=blocks&bkprop=range&bkip=2002%3AB752%3AD225%3A0%3A0%3A0%3A0%3A1
Change-Id: I6138240bb03bbf5af61851d3e96354a050e56fed
$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