Closed DrLightman closed 4 years ago
Hello, getting this message upon this kind of request for getDailySearchTrends:
$hl = "en-ZW"; $tz = 60; $geo = "ZW";
Originated in this block:
try { $dataJson = $this->_getData(self::DAILY_SEARCH_TRENDS_ENDPOINT, 'GET', $params); return Json\Json::decode(trim(substr($dataJson, 5)), Json\Json::TYPE_ARRAY); } catch (\Exception $e) { die($e->getMessage()); }
Not sure why it happens, but it looks like when the returned $dataJson is FALSE for whatever the reason, the app literally dies. Couldn't be falsy returned instead?
$dataJson
I suppose yes, can be a good idea to return false instead of die(). I will take it in consideration. Thank you.
Hello, getting this message upon this kind of request for getDailySearchTrends:
Originated in this block:
Not sure why it happens, but it looks like when the returned
$dataJson
is FALSE for whatever the reason, the app literally dies. Couldn't be falsy returned instead?