Im getting the following exeption:
Exception - Call to a member function add grade condition() on null
Im trying to add a grade condition for complition to a certain activity in a course. Im ussing this command:
$quiz1->add_grade_condition($qidingradeitem,$thresholdgrade,null,true);
the $qidingradeitem stores the id of the activity from the mdl_grade_items table and the $thresholdgrade stores the grade it will be set to minimumgrade in the DB.
Could someone tell me what I'm missing or doing wrong?