Fixed regression: server status was reset

SVN:code[161]
This commit is contained in:
Romain Quetiez
2009-09-16 07:53:12 +00:00
parent 56c70ee33b
commit 4517c61049
2 changed files with 13 additions and 5 deletions

View File

@@ -428,12 +428,16 @@ switch($operation)
}
else if (!$oAttDef->IsExternalField())
{
$aAttributes[$sAttCode] = trim(utils::ReadPostedParam("attr_$sAttCode", null));
$previousValue = $oObj->Get($sAttCode);
if (!is_null($aAttributes[$sAttCode]) && ($previousValue != $aAttributes[$sAttCode]))
$rawValue = utils::ReadPostedParam("attr_$sAttCode", null);
if (!is_null($rawValue))
{
$oObj->Set($sAttCode, $aAttributes[$sAttCode]);
$bObjectModified = true;
$aAttributes[$sAttCode] = trim($rawValue);
$previousValue = $oObj->Get($sAttCode);
if ($previousValue != $aAttributes[$sAttCode])
{
$oObj->Set($sAttCode, $aAttributes[$sAttCode]);
$bObjectModified = true;
}
}
}
}