mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2024-11-15 11:28:25 +00:00
Add removed getDataSource() call.
This fixes an issue where the wrong datasource could potentially be used for getting the full table name.
This commit is contained in:
parent
7dae12456a
commit
0bbf61ce3d
1 changed files with 1 additions and 0 deletions
|
@ -257,6 +257,7 @@ class CakeSchema extends Object {
|
||||||
if (!is_object($Object) || $Object->useTable === false) {
|
if (!is_object($Object) || $Object->useTable === false) {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
$db = $Object->getDataSource();
|
||||||
|
|
||||||
$fulltable = $table = $db->fullTableName($Object, false, false);
|
$fulltable = $table = $db->fullTableName($Object, false, false);
|
||||||
if ($prefix && strpos($table, $prefix) !== 0) {
|
if ($prefix && strpos($table, $prefix) !== 0) {
|
||||||
|
|
Loading…
Reference in a new issue