Skip to content

Commit 19db1df

Browse files
fix: buzz response factory (#250)
Fixes the instantiation of Buzz client to use the new `Psr17FactoryDiscovery` instead of the deprecated `MessageFactoryDiscovery`.
1 parent 1856a11 commit 19db1df

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

src/Strategy/CommonClassesStrategy.php

+1-2
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@
1818
use Http\Client\Socket\Client as Socket;
1919
use Http\Discovery\ClassDiscovery;
2020
use Http\Discovery\Exception\NotFoundException;
21-
use Http\Discovery\MessageFactoryDiscovery;
2221
use Http\Discovery\Psr17FactoryDiscovery;
2322
use Http\Message\MessageFactory;
2423
use Http\Message\MessageFactory\DiactorosMessageFactory;
@@ -146,7 +145,7 @@ private static function getPsr18Candidates()
146145

147146
public static function buzzInstantiate()
148147
{
149-
return new \Buzz\Client\FileGetContents(MessageFactoryDiscovery::find());
148+
return new \Buzz\Client\FileGetContents(Psr17FactoryDiscovery::findResponseFactory());
150149
}
151150

152151
public static function symfonyPsr18Instantiate()

0 commit comments

Comments
 (0)