be more careful with returned table def for schema
This commit is contained in:
parent
1040f1346c
commit
13e1fab919
|
@ -107,9 +107,11 @@ class Schema
|
|||
{
|
||||
$td = $this->getTableDef($table);
|
||||
|
||||
foreach ($td->columns as $cd) {
|
||||
if ($cd->name == $column) {
|
||||
return $cd;
|
||||
if (!empty($td) && !empty($td->columns)) {
|
||||
foreach ($td->columns as $cd) {
|
||||
if ($cd->name == $column) {
|
||||
return $cd;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user