Commit 15bf4d70 authored by Jonathan.Wage's avatar Jonathan.Wage

Fixed issue with specifying directory as schema

parent caa3f476
...@@ -102,7 +102,7 @@ class Doctrine_Import_Schema ...@@ -102,7 +102,7 @@ class Doctrine_Import_Schema
$array = array(); $array = array();
foreach ((array) $schema AS $s) { foreach ((array) $schema AS $s) {
if (is_file($s) || is_string($s)) { if (is_file($s)) {
$array = array_merge($array, $this->parseSchema($s, $format)); $array = array_merge($array, $this->parseSchema($s, $format));
} else if (is_dir($s)) { } else if (is_dir($s)) {
$it = new RecursiveIteratorIterator(new RecursiveDirectoryIterator($s), $it = new RecursiveIteratorIterator(new RecursiveDirectoryIterator($s),
...@@ -114,6 +114,8 @@ class Doctrine_Import_Schema ...@@ -114,6 +114,8 @@ class Doctrine_Import_Schema
$array = array_merge($array, $this->parseSchema($file->getPathName(), $format)); $array = array_merge($array, $this->parseSchema($file->getPathName(), $format));
} }
} }
} else {
$array = array_merge($array, $this->parseSchema($s, $format));
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment