Skip to content

Commit

Permalink
fix bug developer metric and require filesystem
Browse files Browse the repository at this point in the history
  • Loading branch information
leonardovilarinho committed Oct 26, 2017
1 parent 752b9df commit 0d46c22
Show file tree
Hide file tree
Showing 4 changed files with 57 additions and 56 deletions.
5 changes: 3 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"type": "framework",
"license": "GPL-3.0",
"minimum-stability": "stable",
"version": "1.0.3",
"version": "1.0.4",
"authors": [
{
"name": "Leonardo Vilarinho",
Expand Down Expand Up @@ -44,7 +44,8 @@
"symfony/yaml": "^3.3",
"symfony/process": "^3.3",
"symfony/console": "^3.3",
"duncan3dc/fork-helper": "^2.2"
"duncan3dc/fork-helper": "^2.2",
"symfony/filesystem": "^3.3"
},
"require-dev": {
"phpunit/phpunit": "^6.2",
Expand Down
102 changes: 51 additions & 51 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions source/Metrics/DevelopersMetric.php
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,8 @@ public static function generate(OutputInterface $output)
unset($line[0]);
$line[1] = isset($line[1]) ? trim($line[1]) : 0;
$line[2] = isset($line[2]) ? trim($line[2]) : 0;
self::$developers[$dev]['inserts'] += $line[1];
self::$developers[$dev]['deletions'] += $line[2];
self::$developers[$dev]['inserts'] += (int)$line[1];
self::$developers[$dev]['deletions'] += (int)$line[2];
}
}
$progress->advance();
Expand Down
2 changes: 1 addition & 1 deletion source/Program/ExportServices/IExport.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,5 @@ interface IExport
{
public function __construct(ClassesRepository $repository, array $devs, OutputInterface $output);

public function export(string $path, float $stars, string $alias = null);
public function export(string $path, float $stars, string $alias = '');
}

0 comments on commit 0d46c22

Please sign in to comment.