From 0589b3e2299f1a87b4ed7912183e5e59378ad481 Mon Sep 17 00:00:00 2001 From: Uwe Tesche Date: Mon, 18 Jul 2022 16:13:15 +0200 Subject: [PATCH] bugfix: the Language to be set MUST not be NULL otherwise a TypeError Exception is raised: TypeError thrown with message "Argument 1 passed to ilObjUser::setLanguage() must be of the type string, null given, called in /.../Services/User/classes/class.ilUserImportParser.php on line 467" Stacktrace: #16 TypeError in /.../Services/User/classes/class.ilObjUser.php:1479 #15 ilObjUser:setLanguage in /.../Services/User/classes/class.ilUserImportParser.php:467 #14 ilUserImportParser:importBeginTag in /.../Services/User/classes/class.ilUserImportParser.php:364 #13 ilUserImportParser:handlerBeginTag in [internal]:0 --- Services/User/classes/class.ilUserImportParser.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Services/User/classes/class.ilUserImportParser.php b/Services/User/classes/class.ilUserImportParser.php index fcd8af3d4a85..0c26eb3d0d1c 100755 --- a/Services/User/classes/class.ilUserImportParser.php +++ b/Services/User/classes/class.ilUserImportParser.php @@ -464,7 +464,7 @@ public function importBeginTag( $ilias->ini->readVariable("layout", "style") ); - $this->userObj->setLanguage($a_attribs["Language"]); + $this->userObj->setLanguage($a_attribs["Language"] ?? ''); $this->userObj->setImportId($a_attribs["Id"]); $this->action = (is_null($a_attribs["Action"])) ? "Insert" : $a_attribs["Action"]; $this->currPassword = null;