Skip to content
Snippets Groups Projects
Commit bc371868 authored by Demian Katz's avatar Demian Katz Committed by Robert Lange
Browse files

Fix database upgrader mediumtext support.

parent 54a510cc
No related merge requests found
......@@ -171,7 +171,7 @@ CREATE TABLE `external_session` (
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `shortlinks` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`path` MEDIUMTEXT NOT NULL,
`path` mediumtext NOT NULL,
`created` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE utf8_bin;
......
......@@ -791,7 +791,9 @@ class DbUpgrade extends AbstractPlugin
// If it's not a blob or a text (which don't have explicit sizes in our SQL),
// we should see what the character length is, if any:
if ($type != 'blob' && $type != 'text' && $type != 'longtext') {
if ($type != 'blob' && $type != 'text' && $type !== 'mediumtext'
&& $type != 'longtext'
) {
$charLen = $column->getCharacterMaximumLength();
if ($charLen) {
$type .= '(' . $charLen . ')';
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment