Open leexin opened 1 year ago
Sorry I didn't find such a problem in PHP 8.1
@zhouaini528 same issue as mentioned in OKEX here https://github.com/zhouaini528/okex-php/issues/5
@zhouaini528 same issue as mentioned in OKEX here zhouaini528/okex-php#5
Thanks for the discovery, I have solved the problem.
method_exists(): Argument #1 ($object_or_class) must be of type object|string, null given
0 /var/www/vendor/linwj/huobi/src/Request.php(167): method_exists()
1 /var/www/vendor/linwj/huobi/src/Api/Spot/Order.php(21): Lin\Huobi\Request->exec()
When submitting order to Huobi calling $client->order()->postPlace() Using PHP8.1
Probable fix to linwj/huobi/src/Request.php and linwj/binance/src/Request.php (might affect other exchanges Request.php too)
if(method_exists($e->getResponse(),'getBody')){
to be changed toif( !empty($e->getResponse()) && method_exists($e->getResponse(),'getBody')){