Fix for completely erroneous DBAL error

This should not work, but somehow does.

¯\_(ツ)_/¯
(╯° °)╯︵ ┻━┻

I hate computers.
This commit is contained in:
snipe 2017-04-27 16:56:15 -07:00
parent 841e3efe96
commit d7f6d8e997

View file

@ -19,6 +19,7 @@ use Illuminate\Database\Schema\Blueprint;
*/
function updateLegacyColumnName($customfield) {
$name_to_db_name = CustomField::name_to_db_name($customfield->name);
\Log::debug('Trying to rename '.$name_to_db_name." to ".$customfield->convertUnicodeDbSlug()."...\n");
@ -48,6 +49,8 @@ class FixUtf8CustomFieldColumnNames extends Migration
*/
public function up()
{
$platform = Schema::getConnection()->getDoctrineSchemaManager()->getDatabasePlatform();
$platform->registerDoctrineTypeMapping('enum', 'string');
Schema::table('custom_fields', function ($table) {
$table->string('db_column')->nullable();