public function __construct(LoggerInterface $logger = null) { if (!is_null($logger)) { $this->setLogger($logger); } }