Skip to content

Commit da7545d

Browse files
committed
fix str_replace statements processor.php
1 parent 31d8ec0 commit da7545d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

classes/processor.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -261,7 +261,7 @@ public function get_triggercourses_forcounting($trigger, $exclude) {
261261
// Get SQL for this trigger.
262262
[$sql, $whereparams] = $lib->get_course_recordset_where($trigger->id);
263263
// We just want the triggered courses here, no matter of including or excluding.
264-
$where = str_replace(" NOT ", "", $sql);
264+
$where = str_replace(" NOT ", " ", $sql);
265265
// Exclude courses in steps of this wf, delayed courses and sitecourse according to the workflow settings.
266266
if (!empty($exclude)) {
267267
[$insql, $inparams] = $DB->get_in_or_equal($exclude, SQL_PARAMS_NAMED);
@@ -317,7 +317,7 @@ public function get_triggercourses($trigger, $workflow) {
317317
// Get SQL for this trigger.
318318
[$sql, $whereparams] = $lib->get_course_recordset_where($trigger->id);
319319
// We just want the triggered courses here, no matter of including or excluding.
320-
$where = str_replace(" NOT ", "", $sql);
320+
$where = str_replace(" NOT ", " ", $sql);
321321
if (!empty($excludedcourses)) {
322322
[$insql, $inparams] = $DB->get_in_or_equal($excludedcourses, SQL_PARAMS_NAMED);
323323
$where .= " AND NOT {course}.id {$insql}";

0 commit comments

Comments
 (0)