Errors in log of rest api plugin
« on: December 05, 2023, 08:01:03 PM »
I have two frequent errors in the error_log file generated in oc-content/plugins/rest folder.

PHP Warning:  Undefined array key "pk_i_id" in /mypath/oc-content/plugins/osclass_pay/email.php on line 89

PHP Warning:  Undefined variable $ub in /mypath/oc-content/plugins/rest/functions.php on line 89

Can you identify if it is something in my osclass installation or an incorrect configuration, or could it be an "improvement waiting to be implemented"/bug ?

Thanks,
Pete

*

MB Themes

Re: Errors in log of rest api plugin
« Reply #1 on: December 06, 2023, 01:20:47 PM »
Osclass pay - in that file, find line:
Code: [Select]
function osp_email_promote($item) {

replace it with:
Code: [Select]
function osp_email_promote($item) {
  if(!isset($item['pk_i_id']) || $item['pk_i_id'] <= 0) {
    return false;
  }

Rest api - in that file, on line 60 add:
Code: [Select]
$ub = '';
  To get fast support, we need following details: Detail description, URL to reproduce problem, Screenshots