From a975117eaf25c6f67171289832d790a4f4ed5cf8 Mon Sep 17 00:00:00 2001 From: Wes Hulette Date: Wed, 17 Oct 2018 16:38:13 -0400 Subject: [PATCH] Fixed: #6325 & #6317 (#6335) * Fixed missing oauth tables during setup. * Fixed missing manager_id and department_id --- app/Importer/Importer.php | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/app/Importer/Importer.php b/app/Importer/Importer.php index 2589bf71b0..d8b5305033 100644 --- a/app/Importer/Importer.php +++ b/app/Importer/Importer.php @@ -320,14 +320,14 @@ abstract class Importer // No Luck, let's create one. $user = new User; - $user->first_name = $user_array['first_name']; - $user->last_name = $user_array['last_name']; - $user->username = $user_array['username']; - $user->email = $user_array['email']; - $user->manager_id = $user_array['manager_id']; - $user->department_id = $user_array['department_id']; - $user->activated = 1; - $user->password = $this->tempPassword; + $user->first_name = $user_array['first_name']; + $user->last_name = $user_array['last_name']; + $user->username = $user_array['username']; + $user->email = $user_array['email']; + $user->manager_id = $user_array['manager_id'] ?? null; + $user->department_id = $user_array['department_id'] ?? null; + $user->activated = 1; + $user->password = $this->tempPassword; if ($user->save()) { $this->log('User '.$user_array['username'].' created');