mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2025-01-19 02:56:15 +00:00
Optimization when checking for setTable prefix.
git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@7370 3807eeeb-6ff5-0310-8944-8be069107fe0
This commit is contained in:
parent
460b219810
commit
ac45340a71
1 changed files with 1 additions and 2 deletions
|
@ -348,8 +348,7 @@ class Model extends Overloadable {
|
||||||
if ($this->useTable === null) {
|
if ($this->useTable === null) {
|
||||||
$this->useTable = Inflector::tableize($this->name);
|
$this->useTable = Inflector::tableize($this->name);
|
||||||
}
|
}
|
||||||
$methods = get_class_methods($this);
|
if (method_exists($this, 'setTablePrefix')) {
|
||||||
if (in_array('settableprefix', $methods) || in_array('setTablePrefix', $methods)) {
|
|
||||||
$this->setTablePrefix();
|
$this->setTablePrefix();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue