Skip to content

Commit 15120a4

Browse files
committed
Added the logger to Admin
1 parent ff93e20 commit 15120a4

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/Gitonomy/Git/Admin.php

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212

1313
namespace Gitonomy\Git;
1414

15+
use Psr\Log\LoggerInterface;
1516
use Symfony\Component\Process\ProcessBuilder;
1617

1718
/**
@@ -31,7 +32,7 @@ class Admin
3132
*
3233
* @throws RuntimeException Directory exists or not writable
3334
*/
34-
public static function init($path, $bare = true)
35+
public static function init($path, $bare = true, LoggerInterface $logger = null)
3536
{
3637
$builder = ProcessBuilder::create(array('git', 'init', '-q'));
3738

@@ -48,6 +49,6 @@ public static function init($path, $bare = true)
4849
throw new \RuntimeException(sprintf('Error while initializing repository: %s', $process->getErrorOutput()));
4950
}
5051

51-
return new Repository($path);
52+
return new Repository($path, null, $logger);
5253
}
5354
}

0 commit comments

Comments
 (0)