From 2f12a9cfe2d5a666abe5fdbd805d264993dba9cc Mon Sep 17 00:00:00 2001 From: Godfrey M Date: Thu, 16 Nov 2023 09:52:44 -0800 Subject: [PATCH] add a conditional around location_id to fix bug --- app/Console/Commands/LdapSync.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/Console/Commands/LdapSync.php b/app/Console/Commands/LdapSync.php index edb29614e..e11d269ef 100755 --- a/app/Console/Commands/LdapSync.php +++ b/app/Console/Commands/LdapSync.php @@ -83,7 +83,7 @@ class LdapSync extends Command $summary = []; try { - if ( $this->option('location_id') != '') { + if ( !empty($this->option('location_id')) != '') { $location_ou= Location::where('id', '=', $this->option('location_id'))->value('ldap_ou'); $search_base = $location_ou; Log::debug('Importing users from specified location OU: \"'.$search_base.'\".');