From 88548515255a0ab9f79f1db2646dc6ee49447474 Mon Sep 17 00:00:00 2001 From: Dan Marsden Date: Thu, 24 Sep 2020 11:47:34 +1200 Subject: [PATCH] user session import - make user key case insensitive. --- classes/import/marksessions.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/classes/import/marksessions.php b/classes/import/marksessions.php index 8a00a7f..7da34df 100644 --- a/classes/import/marksessions.php +++ b/classes/import/marksessions.php @@ -190,7 +190,7 @@ class marksessions { if (!empty($mappingdata) && $mappingdata->userto !== 'id') { foreach ($validusers as $u) { if (!empty($u->{$mappingdata->userto})) { - $users[$u->{$mappingdata->userto}] = $u; + $users[strtolower($u->{$mappingdata->userto})] = $u; } } } else { @@ -214,7 +214,7 @@ class marksessions { $mapping = $this->read_mapping_data($mappingdata); // Get user. - $extuser = $this->get_column_data($row, $mapping['user']); + $extuser = strtolower($this->get_column_data($row, $mapping['user'])); if (empty($users[$extuser])) { $a = new \stdClass(); $a->extuser = $extuser;