fix for mysql export module (allow specifying a default without specifying a length)
This commit is contained in:
parent
f1c6657c0f
commit
9b4f5db135
@ -500,7 +500,7 @@ class Doctrine_Export_Mysql extends Doctrine_Export
|
|||||||
public function getDefaultFieldDeclaration($field)
|
public function getDefaultFieldDeclaration($field)
|
||||||
{
|
{
|
||||||
$default = '';
|
$default = '';
|
||||||
if (isset($field['default']) && $field['length'] <= 255) {
|
if (isset($field['default']) && ( ! isset($field['length']) || $field['length'] <= 255)) {
|
||||||
if ($field['default'] === '') {
|
if ($field['default'] === '') {
|
||||||
$field['default'] = empty($field['notnull'])
|
$field['default'] = empty($field['notnull'])
|
||||||
? null : $this->valid_default_values[$field['type']];
|
? null : $this->valid_default_values[$field['type']];
|
||||||
|
Loading…
Reference in New Issue
Block a user