Skip to content

Commit

Permalink
Ensure every responses exceptions are instance of HttpException
Browse files Browse the repository at this point in the history
  • Loading branch information
evaisse committed Jul 13, 2015
1 parent 11610ea commit 5c8edb2
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions Http/Exception/ResponseException.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@

namespace evaisse\SimpleHttpBundle\Http\Exception;

use evaisse\SimpleHttpBundle\Http\Exception;
use evaisse\SimpleHttpBundle\Http\Response;
use Symfony\Component\HttpKernel\Exception\HttpException;


class ResponseException extends Exception
class ResponseException extends HttpException
{

/**
Expand All @@ -30,7 +30,7 @@ class ResponseException extends Exception
* @param Response $response response attached to error
* @param string $message Message describing exception
* @param int $code error code
* @param Exception $previous optionnal previous exception
* @param \Exception $previous optionnal previous exception
*/
public function __construct(Response $response, $message = "", $code = 0, \Exception $previous = null)
{
Expand All @@ -41,7 +41,7 @@ public function __construct(Response $response, $message = "", $code = 0, \Excep
/**
* Set value for $response
*
* @param ServiceResponse $value value to set to response
* @param Response $value value to set to response
* @return Object instance for method chaining
*/
protected function setResponse(Response $value)
Expand Down

0 comments on commit 5c8edb2

Please sign in to comment.