In `wpdb::get_col_length()`, `break`s are not necessary when a `case` returns
See #33491. Built from https://develop.svn.wordpress.org/trunk@33701 git-svn-id: http://core.svn.wordpress.org/trunk@33668 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
3982598305
commit
029c274b86
|
@ -4,7 +4,7 @@
|
|||
*
|
||||
* @global string $wp_version
|
||||
*/
|
||||
$wp_version = '4.4-alpha-33700';
|
||||
$wp_version = '4.4-alpha-33701';
|
||||
|
||||
/**
|
||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||
|
|
|
@ -2482,42 +2482,42 @@ class wpdb {
|
|||
'type' => 'char',
|
||||
'length' => (int) $length,
|
||||
);
|
||||
break;
|
||||
|
||||
case 'binary':
|
||||
case 'varbinary':
|
||||
return array(
|
||||
'type' => 'byte',
|
||||
'length' => (int) $length,
|
||||
);
|
||||
break;
|
||||
|
||||
case 'tinyblob':
|
||||
case 'tinytext':
|
||||
return array(
|
||||
'type' => 'byte',
|
||||
'length' => 255, // 2^8 - 1
|
||||
);
|
||||
break;
|
||||
|
||||
case 'blob':
|
||||
case 'text':
|
||||
return array(
|
||||
'type' => 'byte',
|
||||
'length' => 65535, // 2^16 - 1
|
||||
);
|
||||
break;
|
||||
|
||||
case 'mediumblob':
|
||||
case 'mediumtext':
|
||||
return array(
|
||||
'type' => 'byte',
|
||||
'length' => 16777215, // 2^24 - 1
|
||||
);
|
||||
break;
|
||||
|
||||
case 'longblob':
|
||||
case 'longtext':
|
||||
return array(
|
||||
'type' => 'byte',
|
||||
'length' => 4294967295, // 2^32 - 1
|
||||
);
|
||||
break;
|
||||
|
||||
default:
|
||||
return false;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue