mirror of
https://github.com/Combodo/iTop.git
synced 2026-04-24 11:08:45 +02:00
N°5618 - Setup : Compatibility PHP 8.1
This commit is contained in:
@@ -2270,7 +2270,7 @@ class Config
|
|||||||
$oHandle = null;
|
$oHandle = null;
|
||||||
$sConfig = null;
|
$sConfig = null;
|
||||||
|
|
||||||
if (is_file($this->m_sFile))
|
if ($this->m_sFile!= null && is_file($this->m_sFile))
|
||||||
{
|
{
|
||||||
$oHandle = fopen($this->m_sFile, 'r');
|
$oHandle = fopen($this->m_sFile, 'r');
|
||||||
$index = 0;
|
$index = 0;
|
||||||
|
|||||||
@@ -348,7 +348,7 @@ abstract class User extends cmdbAbstractObject
|
|||||||
$aChanges = $this->ListChanges();
|
$aChanges = $this->ListChanges();
|
||||||
if (array_key_exists('login', $aChanges)) {
|
if (array_key_exists('login', $aChanges)) {
|
||||||
// Check login uniqueness
|
// Check login uniqueness
|
||||||
if (strcasecmp($this->Get('login'), $this->GetOriginal('login')) !== 0) {
|
if ( $this->GetOriginal('login')== null || strcasecmp($this->Get('login'), $this->GetOriginal('login')) !== 0) {
|
||||||
$sNewLogin = $aChanges['login'];
|
$sNewLogin = $aChanges['login'];
|
||||||
$oSearch = DBObjectSearch::FromOQL_AllData("SELECT User WHERE login = :newlogin");
|
$oSearch = DBObjectSearch::FromOQL_AllData("SELECT User WHERE login = :newlogin");
|
||||||
if (!$this->IsNew()) {
|
if (!$this->IsNew()) {
|
||||||
|
|||||||
Reference in New Issue
Block a user