Permalink
Browse files

Fixed bug in UpgradeShell::findFiles().

$this->_files was reset on each loop through paths, which means, for
example, if you still had the old 'views' directory kicking around
the results from 'View' would be overwritten.
  • Loading branch information...
1 parent 4368b62 commit c966a35bebda6f79c1c79a835367ba17f5d1a0d5 @jamiemill jamiemill committed Nov 6, 2011
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/Cake/Console/Command/UpgradeShell.php
@@ -702,11 +702,11 @@ protected function _filesRegexpUpdate($patterns) {
* @return void
*/
protected function _findFiles($extensions = '') {
+ $this->_files = array();
foreach ($this->_paths as $path) {
if (!is_dir($path)) {
continue;
}
- $this->_files = array();
$Iterator = new RegexIterator(
new RecursiveIteratorIterator(new RecursiveDirectoryIterator($path)),
'/^.+\.(' . $extensions . ')$/i',

0 comments on commit c966a35

Please sign in to comment.