mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2025-01-19 02:56:15 +00:00
fixing tests from last merge
This commit is contained in:
parent
d9c99b5ef6
commit
2386a11151
1 changed files with 3 additions and 6 deletions
|
@ -95,10 +95,7 @@ class ConnectionManager {
|
||||||
self::_getConnectionObject($name);
|
self::_getConnectionObject($name);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (empty(self::$_connectionsEnum[$name])) {
|
self::loadDataSource($name);
|
||||||
throw new MissingDatasourceConfigException(array('config' => $name));
|
|
||||||
}
|
|
||||||
|
|
||||||
$conn = self::$_connectionsEnum[$name];
|
$conn = self::$_connectionsEnum[$name];
|
||||||
$class = $conn['classname'];
|
$class = $conn['classname'];
|
||||||
|
|
||||||
|
@ -173,7 +170,7 @@ class ConnectionManager {
|
||||||
|
|
||||||
App::uses($conn['classname'], $plugin . 'Model/Datasource' . $package);
|
App::uses($conn['classname'], $plugin . 'Model/Datasource' . $package);
|
||||||
if (!class_exists($conn['classname'])) {
|
if (!class_exists($conn['classname'])) {
|
||||||
throw new MissingDatasourceFileException(array('class' => $conn['classname'], 'plugin' => $conn['plugin']));
|
throw new MissingDatasourceFileException(array('class' => $conn['classname'], 'plugin' => $plugin));
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
@ -222,7 +219,7 @@ class ConnectionManager {
|
||||||
if (!empty(self::$config->{$name})) {
|
if (!empty(self::$config->{$name})) {
|
||||||
self::$_connectionsEnum[$name] = self::_connectionData(self::$config->{$name});
|
self::$_connectionsEnum[$name] = self::_connectionData(self::$config->{$name});
|
||||||
} else {
|
} else {
|
||||||
throw new MissingConnectionException(array('class' => $name));
|
throw new MissingDatasourceConfigException(array('config' => $name));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue