From 5047143e7b8d1733fac9d79da39de00a91e49db1 Mon Sep 17 00:00:00 2001 From: Fred Condo Date: Wed, 18 Feb 2015 10:30:07 -0800 Subject: [PATCH] Correct return statements in SS_HTTPResponse - setBody failed to return a value; it now returns $this as related methods do - getHeader had an extra, unreachable return statement; removed --- control/HTTPResponse.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/control/HTTPResponse.php b/control/HTTPResponse.php index dbcfec613..1df15f913 100644 --- a/control/HTTPResponse.php +++ b/control/HTTPResponse.php @@ -161,6 +161,7 @@ class SS_HTTPResponse { */ public function setBody($body) { $this->body = $body ? (string)$body : $body; // Don't type-cast false-ish values, eg null is null not '' + return $this; } /** @@ -191,7 +192,6 @@ class SS_HTTPResponse { public function getHeader($header) { if(isset($this->headers[$header])) return $this->headers[$header]; - return null; } /**