mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2024-11-15 11:28:25 +00:00
change method public unsigned
to protected _unsigned
This commit is contained in:
parent
1313b81913
commit
f817beb8b6
1 changed files with 11 additions and 11 deletions
|
@ -350,7 +350,7 @@ class Mysql extends DboSource {
|
||||||
'length' => $this->length($column->Type)
|
'length' => $this->length($column->Type)
|
||||||
);
|
);
|
||||||
if (in_array($fields[$column->Field]['type'], $this->fieldParameters['unsigned']['types'], true)) {
|
if (in_array($fields[$column->Field]['type'], $this->fieldParameters['unsigned']['types'], true)) {
|
||||||
$fields[$column->Field]['unsigned'] = $this->unsigned($column->Type);
|
$fields[$column->Field]['unsigned'] = $this->_unsigned($column->Type);
|
||||||
}
|
}
|
||||||
if (!empty($column->Key) && isset($this->index[$column->Key])) {
|
if (!empty($column->Key) && isset($this->index[$column->Key])) {
|
||||||
$fields[$column->Field]['key'] = $this->index[$column->Key];
|
$fields[$column->Field]['key'] = $this->index[$column->Key];
|
||||||
|
@ -785,16 +785,6 @@ class Mysql extends DboSource {
|
||||||
return 'text';
|
return 'text';
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Check if column type is unsigned
|
|
||||||
*
|
|
||||||
* @param string $real Real database-layer column type (i.e. "varchar(255)")
|
|
||||||
* @return bool True if column is unsigned, false otherwise
|
|
||||||
*/
|
|
||||||
public function unsigned($real) {
|
|
||||||
return strpos(strtolower($real), 'unsigned') !== false;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Gets the schema name
|
* Gets the schema name
|
||||||
*
|
*
|
||||||
|
@ -813,4 +803,14 @@ class Mysql extends DboSource {
|
||||||
return $this->useNestedTransactions && version_compare($this->getVersion(), '4.1', '>=');
|
return $this->useNestedTransactions && version_compare($this->getVersion(), '4.1', '>=');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Check if column type is unsigned
|
||||||
|
*
|
||||||
|
* @param string $real Real database-layer column type (i.e. "varchar(255)")
|
||||||
|
* @return bool True if column is unsigned, false otherwise
|
||||||
|
*/
|
||||||
|
protected function _unsigned($real) {
|
||||||
|
return strpos(strtolower($real), 'unsigned') !== false;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue