Created
September 28, 2016 13:23
-
-
Save mchelen/812a8c1f524f9a280a1b019ec0929ca7 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace Example; | |
class Foo { | |
private $logger; | |
__construct (\Psr\Log\LoggerInterface $logger = new \Psr\Log\NullLogger()) { | |
$this->logger = $logger; | |
} | |
public function bar($baz) { | |
$this->logger->addDebug($baz); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
doesn't work because of example #4 http://php.net/manual/en/functions.arguments.php