33namespace Http \HttplugBundle \ClientFactory ;
44
55use Http \Client \Curl \Client ;
6- use Http \Message \MessageFactory ;
7- use Http \Message \StreamFactory ;
6+ use Psr \ Http \Message \ResponseFactoryInterface ;
7+ use Psr \ Http \Message \StreamFactoryInterface ;
88
99/**
1010 * @author Tobias Nyholm <[email protected] > 1111 */
1212class CurlFactory implements ClientFactory
1313{
1414 /**
15- * @var MessageFactory
15+ * @var ResponseFactoryInterface
1616 */
17- private $ messageFactory ;
17+ private $ responseFactory ;
1818
1919 /**
20- * @var StreamFactory
20+ * @var StreamFactoryInterface
2121 */
2222 private $ streamFactory ;
2323
2424 /**
25- * @param MessageFactory $messageFactory
26- * @param StreamFactory $streamFactory
25+ * @param ResponseFactoryInterface $responseFactory
26+ * @param StreamFactoryInterface $streamFactory
2727 */
28- public function __construct (MessageFactory $ messageFactory , StreamFactory $ streamFactory )
28+ public function __construct (ResponseFactoryInterface $ responseFactory , StreamFactoryInterface $ streamFactory )
2929 {
30- $ this ->messageFactory = $ messageFactory ;
30+ $ this ->responseFactory = $ responseFactory ;
3131 $ this ->streamFactory = $ streamFactory ;
3232 }
3333
@@ -53,6 +53,6 @@ public function createClient(array $config = [])
5353 }
5454 }
5555
56- return new Client ($ this ->messageFactory , $ this ->streamFactory , $ config );
56+ return new Client ($ this ->responseFactory , $ this ->streamFactory , $ config );
5757 }
5858}
0 commit comments