MDL-33682 backup: keep old behavior, aka, use section number on empty section name.
[moodle.git] / backup / util / factories / backup_factory.class.php
index e58650d..e2143cd 100644 (file)
@@ -139,7 +139,7 @@ abstract class backup_factory {
             throw new backup_task_exception('section_task_section_not_found', $sectionid);
         }
 
-        return new backup_section_task((string)$section->name !== '' ? $section->section : $section->name, $sectionid);
+        return new backup_section_task((string)$section->name === '' ? $section->section : $section->name, $sectionid);
     }
 
     /**