From 0ce540c84ab69b5e34f344cadb9ca26c0edca19e Mon Sep 17 00:00:00 2001 From: Arnaud Lejosne Date: Thu, 13 Aug 2015 13:28:21 +0200 Subject: [PATCH] Fix #257 - Prevent symlink paths resolving in fixtures loading --- Command/FixturesLoadCommand.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Command/FixturesLoadCommand.php b/Command/FixturesLoadCommand.php index 4830602..49f8f12 100644 --- a/Command/FixturesLoadCommand.php +++ b/Command/FixturesLoadCommand.php @@ -277,7 +277,9 @@ EOT protected function getFixtureFiles($type = 'sql', $in = null) { $finder = new Finder(); - $finder->sortByName()->name('*.' . $type); + $finder->sort(function ($a, $b) { + return strcmp($a->getPathname(), $b->getPathname()); + })->name('*.' . $type); $files = $finder->in(null !== $in ? $in : $this->absoluteFixturesPath);