1
0
mirror of https://github.com/phpmyadmin/phpmyadmin.git synced 2026-10-29 21:24:44 +03:00

Allow to specify length of 0

Issue #12480

Signed-off-by: Michal Čihař <michal@cihar.com>
This commit is contained in:
Michal Čihař
2016-08-25 14:30:13 +02:00
parent fb3b722da1
commit 33348c5ed5

View File

@@ -399,7 +399,7 @@ class Table
//
$pattern = '@^(DATE|TINYBLOB|TINYTEXT|BLOB|TEXT|'
. 'MEDIUMBLOB|MEDIUMTEXT|LONGBLOB|LONGTEXT|SERIAL|BOOLEAN|UUID)$@i';
if ($length != '' && ! preg_match($pattern, $type)) {
if (strlen($length) !== 0 && ! preg_match($pattern, $type)) {
$query .= '(' . intval($length) . ')';
}