At seemingly random times I'm getting the error: json_decode() expects parameter 1 to be string, null given.
Stack trace:
php
Fatal error: Uncaught TypeError: json_decode() expects parameter 1 to be string, null given in /var/www/html/src/vendor/jeremykendall/php-domain-parser/src/Manager.php on line 111
( ! ) TypeError: json_decode() expects parameter 1 to be string, null given in /var/www/html/src/vendor/jeremykendall/php-domain-parser/src/Manager.php on line 111
Call Stack
# Time Memory Function Location
1 0.0057 424528 {main}( ) .../process.php:0
2 0.0240 532120 Pdp\Manager->getRules( ) .../process.php:214
3 0.5702 536456 json_decode ( ) .../Manager.php:111
Here's how I call manager:
php
require './vendor/autoload.php';
use League\Uri;
use Pdp\Cache;
use Pdp\CurlHttpClient;
use Pdp\Manager;
use Pdp\Rules;
$manager = new Manager(new Cache(), new CurlHttpClient(), '1 DAY');
$rules = $manager->getRules();
Is this a bug?
该提问来源于开源项目:jeremykendall/php-domain-parser