Browse files

Fixed bug #19930 : option --report-file generate an empty file

  • Loading branch information...
1 parent 67d9fa1 commit f1ebd1af453eb4d2e878081bdd6906b65defba18 @gsherwood gsherwood committed May 6, 2013
Showing with 6 additions and 1 deletion.
  1. +5 −1 CodeSniffer/Reporting.php
  2. +1 −0 package.xml
View
6 CodeSniffer/Reporting.php
@@ -143,7 +143,11 @@ public function cacheFileReport(PHP_CodeSniffer_File $phpcsFile, array $cliValue
}
if ($output === null) {
- $output = getcwd().'/phpcs-'.$report.'.tmp';
+ if ($cliValues['reportFile'] !== null) {
+ $output = $cliValues['reportFile'];
+ } else {
+ $output = getcwd().'/phpcs-'.$report.'.tmp';
+ }
}
file_put_contents($output, $generatedReport, $flags);
View
1 package.xml
@@ -40,6 +40,7 @@ http://pear.php.net/dtd/package-2.0.xsd">
-- Thanks to Maik Penz for the patch
- Fixed bug #19892 : ELSE with no braces causes incorrect SWITCH break statement indentation error
- Fixed bug #19908 : PEAR MultiLineCondition Does Not Apply elseif
+ - Fixed bug #19930 : option --report-file generate an empty file
</notes>
<contents>
<dir name="/">

0 comments on commit f1ebd1a

Please sign in to comment.