Skip to content

Commit 7b053fd

Browse files
committed
Fix code analysis workflow
1 parent c6b6609 commit 7b053fd

File tree

4 files changed

+5
-3
lines changed

4 files changed

+5
-3
lines changed

phpstan.neon.dist

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ parameters:
55
level: 5
66
paths:
77
- src
8-
- config
98
- database
109
tmpDir: build/phpstan
1110
checkOctaneCompatibility: true

src/Builder/CsvBuilder.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@ public function build(): string
1414
// Add header row
1515
$csv .= implode(',', $this->columns)."\n";
1616

17+
$csvRow = [];
18+
1719
// Add data rows
1820
foreach ($this->columns as $column) {
1921
if (! array_key_exists($column, $this->data)) {

src/Builder/ExtractBuilder.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ class ExtractBuilder
1717
public const DEFAULT_FORMAT = self::FORMAT_SQL;
1818

1919
public const FORMATS = [
20-
// self::FORMAT_CSV, // TODO: Enable this when ready
20+
self::FORMAT_CSV,
2121
self::FORMAT_SQL,
2222
];
2323

src/Commands/DataExtractCommand.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
namespace NaimSolong\DataExtractor\Commands;
44

55
use Illuminate\Console\Command;
6+
use NaimSolong\DataExtractor\Builder\ExtractBuilder;
67
use NaimSolong\DataExtractor\Dto\Export;
78

89
class DataExtractCommand extends Command
@@ -105,7 +106,7 @@ protected function validateOptions(): bool
105106
return false;
106107
}
107108

108-
if (! in_array($option['export']['format'], Export::FORMATS)) {
109+
if (! in_array($option['export']['format'], ExtractBuilder::FORMATS)) {
109110
$this->error('Invalid export format in option: '.$option['name']);
110111

111112
return false;

0 commit comments

Comments
 (0)