mirror of
https://github.com/Combodo/iTop.git
synced 2026-05-01 22:48:45 +02:00
N°3436 fix Setup
Was blocked because using iTop 3.0.0 with datamodels/2.x dir : \SetupUtils::GetCompatibleDataModelDir wasn't ok with that :o) This method is no more present, and we're calling \SetupUtils::GetLatestDataModelDir only In other words, we're picking the latest datamodel/*.x dir (greatest number)
This commit is contained in:
@@ -1915,19 +1915,6 @@ JS
|
||||
return false;
|
||||
}
|
||||
|
||||
public static function GetCompatibleDataModelDir($sInstalledVersion)
|
||||
{
|
||||
if (preg_match('/^([0-9]+)\./', $sInstalledVersion, $aMatches)) {
|
||||
$sMajorVersion = $aMatches[1];
|
||||
$sDir = APPROOT.'datamodels/'.$sMajorVersion.'.x/';
|
||||
if (is_dir($sDir)) {
|
||||
return $sDir;
|
||||
}
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
public static function GetDataModelVersion($sDatamodelDir)
|
||||
{
|
||||
$sVersionFile = $sDatamodelDir.'version.xml';
|
||||
|
||||
Reference in New Issue
Block a user