Merge branch 'MDL-27174_MOODLE_19_STABLE' of git://github.com/nebgor/moodle into MOODLE_19_STABLE
This commit is contained in:
@@ -44,11 +44,22 @@
|
||||
function assignment_backup_one_mod($bf,$preferences,$assignment) {
|
||||
|
||||
global $CFG;
|
||||
|
||||
|
||||
if ($assignment === 0) { //no active instances of assignment to be backed up - skip backup
|
||||
return false;
|
||||
}
|
||||
|
||||
if (is_numeric($assignment)) {
|
||||
$assignment = get_record('assignment','id',$assignment);
|
||||
}
|
||||
|
||||
|
||||
if (empty($assignment->assignmenttype)) {
|
||||
// No assignment type will cause fatal error below in require_once so bail out now
|
||||
// Probably ended up here by restoring a course into
|
||||
// a moodle without this assignmenttype
|
||||
return false;
|
||||
}
|
||||
|
||||
$status = true;
|
||||
|
||||
//Start mod
|
||||
|
||||
Reference in New Issue
Block a user