Hi, I believe there is a bug in the file src/com/zoho/crm/api/util/JSONConverter.php I'm not sure what the cause is, but in the isRecord request method it checks for mandatory key values. It can produce this error:
com\zoho\crm\api\exception\SDKException Caused by : Trying to access array offset on value of type null
In the for loop starting on line 265, the variable $keyDetail can sometimes be null, and there is guard to check if it is null. I don't know the root cause of why this happens, but it shouldn't with a valid request/record object. Simply putting this code at the start of the loop:
if ($keyDetail == null) continue;
....
Resolves the issue, and the requests complete successfully.
Hi, I believe there is a bug in the file
src/com/zoho/crm/api/util/JSONConverter.php
I'm not sure what the cause is, but in theisRecord
request method it checks for mandatory key values. It can produce this error:com\zoho\crm\api\exception\SDKException Caused by : Trying to access array offset on value of type null
In the for loop starting on line 265, the variable
$keyDetail
can sometimes be null, and there is guard to check if it is null. I don't know the root cause of why this happens, but it shouldn't with a valid request/record object. Simply putting this code at the start of the loop:Resolves the issue, and the requests complete successfully.
Edit: Here is an example of the fix that worked for me: https://github.com/zoho/zohocrm-php-sdk-6.0/pull/10
I don't know the root cause of this issue, and I don't really have time to figure it out. It would be helpful to know what's going on.