1
0
mirror of synced 2024-12-13 22:56:04 +03:00

Fix array_merge so that schemas that are loaded after are merged in to the existing array of schemas.

This commit is contained in:
Jonathan.Wage 2007-11-08 23:49:01 +00:00
parent 5bb4493864
commit 84fb1ecdc4

View File

@ -103,7 +103,7 @@ class Doctrine_Import_Schema
foreach ((array) $schema AS $s) {
if (is_file($s)) {
$array = array_merge($this->parseSchema($s, $format), $array);
$array = array_merge($array, $this->parseSchema($s, $format));
} else if (is_dir($s)) {
$it = new RecursiveIteratorIterator(new RecursiveDirectoryIterator($s),
RecursiveIteratorIterator::LEAVES_ONLY);
@ -111,7 +111,7 @@ class Doctrine_Import_Schema
foreach ($it as $file) {
$e = explode('.', $file->getFileName());
if (end($e) === $format) {
$array = array_merge($this->parseSchema($file->getPathName(), $format), $array);
$array = array_merge($array, $this->parseSchema($file->getPathName(), $format));
}
}
}