Fixed getLoadedModels()
This commit is contained in:
parent
54050f8c81
commit
24a8cef0e6
@ -555,9 +555,9 @@ final class Doctrine
|
|||||||
// file is not the same as the actual model file name itself
|
// file is not the same as the actual model file name itself
|
||||||
if (isset(self::$_loadedModels[$name])) {
|
if (isset(self::$_loadedModels[$name])) {
|
||||||
try {
|
try {
|
||||||
$tmp = self::$_loadedModels[$name];
|
|
||||||
require_once self::$_loadedModels[$name];
|
require_once self::$_loadedModels[$name];
|
||||||
$declaredAfter = get_declared_classes();
|
$declaredAfter = get_declared_classes();
|
||||||
|
// Using array_slice since array_diff is broken is some versions
|
||||||
$foundClasses = array_slice($declaredAfter, count($declaredBefore)-1);
|
$foundClasses = array_slice($declaredAfter, count($declaredBefore)-1);
|
||||||
if ($foundClasses) {
|
if ($foundClasses) {
|
||||||
foreach ($foundClasses as $name) {
|
foreach ($foundClasses as $name) {
|
||||||
|
Loading…
Reference in New Issue
Block a user