fixed PHP error on old versions

This commit is contained in:
Roland Gruber 2018-03-03 10:28:21 +01:00
parent fe44f7b13c
commit 2d2be02b34
1 changed files with 4 additions and 4 deletions

View File

@ -15,11 +15,10 @@ use \Ldap;
use \htmlResponsiveRow; use \htmlResponsiveRow;
use \htmlDiv; use \htmlDiv;
/* /*
$Id$
This code is part of LDAP Account Manager (http://www.ldap-account-manager.org/) This code is part of LDAP Account Manager (http://www.ldap-account-manager.org/)
Copyright (C) 2003 - 2006 Michael Duergner Copyright (C) 2003 - 2006 Michael Duergner
2005 - 2017 Roland Gruber 2005 - 2018 Roland Gruber
This program is free software; you can redistribute it and/or modify This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by it under the terms of the GNU General Public License as published by
@ -501,8 +500,9 @@ if(isset($_POST['checklogin'])) {
$searchFilter = str_replace('%USER%', $username ,$searchFilter); $searchFilter = str_replace('%USER%', $username ,$searchFilter);
$searchDN = ''; $searchDN = '';
$searchPassword = ''; $searchPassword = '';
if (!empty($_SESSION['config']->getLoginSearchDN())) { $configLoginSearchDn = $_SESSION['config']->getLoginSearchDN();
$searchDN = $_SESSION['config']->getLoginSearchDN(); if (!empty($configLoginSearchDn)) {
$searchDN = $configLoginSearchDn;
$searchPassword = $_SESSION['config']->getLoginSearchPassword(); $searchPassword = $_SESSION['config']->getLoginSearchPassword();
} }
$searchSuccess = true; $searchSuccess = true;