Skip to content

Commit

Permalink
Fix bug when language files are at the root
Browse files Browse the repository at this point in the history
Fix #28
  • Loading branch information
MattKetmo committed Nov 14, 2014
1 parent 1009688 commit bdf4678
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/Openl10n/Cli/File/Matcher.php
Original file line number Diff line number Diff line change
Expand Up @@ -84,15 +84,18 @@ public function match($inDir)
}
}


$filePattern = '';
$placeholderStack = $placeholders; // make copy of placeholders
while ($part = array_shift($parts)) {

do {
$part = array_shift($parts);
$filePattern .= $part;

if (null !== $placeholder = array_shift($placeholderStack)) {
$filePattern .= "<${placeholder}>";
}
}
} while(null !== $part);

$results[] = new FileInfo(
$inDir,
Expand Down

0 comments on commit bdf4678

Please sign in to comment.