Permalink
Browse files

MDL-41144 enrol_flatfile: ignore deleted users

  • Loading branch information...
1 parent 14e8af6 commit 1fc4e2b414839ca1651439382d5d892b7cdb0333 @danmarsden danmarsden committed Aug 12, 2013
Showing with 2 additions and 2 deletions.
  1. +2 −2 enrol/flatfile/lib.php
View
@@ -121,8 +121,8 @@ protected function process_file() {
continue;
}
- if (! $user = $DB->get_record("user", array("idnumber"=>$fields[2]))) {
- $this->log .= "Unknown user idnumber in field 3 - ignoring line\n";
+ if (! $user = $DB->get_record("user", array("idnumber"=>$fields[2], 'deleted'=>0))) {
+ $this->log .= "Unknown user idnumber or deleted user in field 3 - ignoring line\n";
continue;
}

0 comments on commit 1fc4e2b

Please sign in to comment.