mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-09 03:32:00 +09:00
Fix various warnings in PHP 8.0
This commit is contained in:
parent
f46b41f437
commit
60465fb2db
23 changed files with 65 additions and 55 deletions
|
|
@ -175,7 +175,7 @@ class DBTableParser extends BaseParser
|
|||
{
|
||||
$index->type = strtoupper($index_info['type']);
|
||||
}
|
||||
elseif (toBool($index_info['unique']))
|
||||
elseif (isset($index_info['unique']) && toBool($index_info['unique']))
|
||||
{
|
||||
$index->type = 'UNIQUE';
|
||||
}
|
||||
|
|
@ -202,12 +202,12 @@ class DBTableParser extends BaseParser
|
|||
{
|
||||
$const_info = self::_getAttributes($const_info);
|
||||
$constraint = new DBTable\Constraint;
|
||||
$constraint->type = strtoupper($const_info['type']);
|
||||
$constraint->column = $const_info['column'] ?: null;
|
||||
$constraint->references = $const_info['references'] ?: null;
|
||||
$constraint->condition = $const_info['condition'] ?: null;
|
||||
$constraint->on_delete = $const_info['ondelete'] ?: $constraint->on_delete;
|
||||
$constraint->on_update = $const_info['onupdate'] ?: $constraint->on_update;
|
||||
$constraint->type = strtoupper($const_info['type'] ?? '');
|
||||
$constraint->column = ($const_info['column'] ?? null) ?: null;
|
||||
$constraint->references = ($const_info['references'] ?? null) ?: null;
|
||||
$constraint->condition = ($const_info['condition'] ?? null) ?: null;
|
||||
$constraint->on_delete = ($const_info['ondelete'] ?? null) ?: $constraint->on_delete;
|
||||
$constraint->on_update = ($const_info['onupdate'] ?? null) ?: $constraint->on_update;
|
||||
$table->constraints[] = $constraint;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue