zendframework/zf2-documentation — pull request #212 by uncle-fred (2012-08-29 18:56:29+00:00)
Title: Removed $this usage when not in object context.

Line 157
is:
Logger::registerErrorHandler($this->logger);
should be:
Logger::registerErrorHandler($logger);

Or even better and to make it more consistent with other examples on the same page I would like to see this code instead (already amended):

$logger = new Zend\Log\Logger;
$writer = new Zend\Log\Writer\Stream('php://output');

$logger->addWriter($writer);

Logger::registerErrorHandler($logger);