Skip to content

Commit

Permalink
Fix return StringResponse in WhoopsRunner handle
Browse files Browse the repository at this point in the history
Handle method return HtmlResponse instead of StringResponse which does not exist anymore in Zend/Diactoros : zendframework/zend-diactoros#61
  • Loading branch information
Fooriva committed Apr 27, 2016
1 parent ec464b2 commit e16f96b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/WhoopsRunner.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
use Whoops\Handler\PrettyPageHandler;
use Whoops\Handler\XmlResponseHandler;
use Whoops\Run;
use Zend\Diactoros\Response\StringResponse;
use Zend\Diactoros\Response\HtmlResponse;

class WhoopsRunner
{
Expand All @@ -25,7 +25,7 @@ public static function handle($error, ServerRequestInterface $request)
$whoops->$method($error);
$response = ob_get_clean();

return StringResponse::html($response, 500);
return new HtmlResponse($response, 500);
}

private static function getWhoopsInstance(ServerRequestInterface $request)
Expand Down

0 comments on commit e16f96b

Please sign in to comment.