mirror of
https://github.com/Combodo/iTop.git
synced 2026-04-22 01:58:47 +02:00
N°1260 Config : migrate DB* variables to the Get() model, create CMDBSource::InitFromConfig
SVN:trunk[5308]
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
<?php
|
||||
// Copyright (C) 2010-2017 Combodo SARL
|
||||
// Copyright (C) 2010-2018 Combodo SARL
|
||||
//
|
||||
// This file is part of iTop.
|
||||
//
|
||||
@@ -194,11 +194,11 @@ if (class_exists('ZipArchive')) // The setup must be able to start even if the "
|
||||
if (is_null($sDBHost))
|
||||
{
|
||||
// Defaulting to the current config
|
||||
$sDBHost = MetaModel::GetConfig()->GetDBHost();
|
||||
$sDBUser = MetaModel::GetConfig()->GetDBUser();
|
||||
$sDBPwd = MetaModel::GetConfig()->GetDBPwd();
|
||||
$sDBName = MetaModel::GetConfig()->GetDBName();
|
||||
$sDBSubName = MetaModel::GetConfig()->GetDBSubName();
|
||||
$sDBHost = MetaModel::GetConfig()->Get('db_host');
|
||||
$sDBUser = MetaModel::GetConfig()->Get('db_user');
|
||||
$sDBPwd = MetaModel::GetConfig()->Get('db_pwd');
|
||||
$sDBName = MetaModel::GetConfig()->Get('db_name');
|
||||
$sDBSubName = MetaModel::GetConfig()->Get('db_subname');
|
||||
}
|
||||
|
||||
// Compute the port (if present in the host name)
|
||||
|
||||
Reference in New Issue
Block a user