MDL-52777 tool_usertours: Only return tours with steps
This commit is contained in:
@@ -579,7 +579,7 @@ EOF;
|
||||
|
||||
foreach ($tours as $record) {
|
||||
$tour = tour::load_from_record($record);
|
||||
if ($tour->is_enabled() && $tour->matches_all_filters($PAGE->context) && $tour->get_steps() > 0) {
|
||||
if ($tour->is_enabled() && $tour->matches_all_filters($PAGE->context) && $tour->count_steps() > 0) {
|
||||
return $tour;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user