From 8982c3246ca6c15e4b7a1cce5362d04c46d7f009 Mon Sep 17 00:00:00 2001 From: Nicolas Grekas Date: Tue, 23 Jun 2015 13:38:55 +0200 Subject: [PATCH] [HttpFoundation] Use convention to allow throwing from __toString() --- src/Symfony/Component/HttpFoundation/Request.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Symfony/Component/HttpFoundation/Request.php b/src/Symfony/Component/HttpFoundation/Request.php index 424a2ed09fec..8babb395c59d 100644 --- a/src/Symfony/Component/HttpFoundation/Request.php +++ b/src/Symfony/Component/HttpFoundation/Request.php @@ -480,7 +480,7 @@ public function __toString() try { $content = $this->getContent(); } catch (\LogicException $e) { - trigger_error($e->getMessage(), E_USER_ERROR); + return trigger_error($e, E_USER_ERROR); } return