mirror of
https://github.com/Combodo/iTop.git
synced 2026-02-13 07:24:13 +01:00
Enhancement: protect RenameValueInDB from non-existent attributes.
SVN:trunk[4357]
This commit is contained in:
@@ -110,6 +110,11 @@ abstract class ModuleInstallerAPI
|
||||
{
|
||||
try
|
||||
{
|
||||
if (!MetaModel::IsValidAttCode($sClass, $sAttCode))
|
||||
{
|
||||
SetupPage::log_warning("Changing enum in DB - $sClass::$sAttCode - from '$sFrom' to '$sTo' failed. Reason '$sAttCode' is not a valid attribute of the class '$sClass'.");
|
||||
return;
|
||||
}
|
||||
$sOriginClass = MetaModel::GetAttributeOrigin($sClass, $sAttCode);
|
||||
$sTableName = MetaModel::DBGetTable($sOriginClass);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user