Fixed bug with the new locking mecanism: lock not released when applying a stimulus

SVN:trunk[3637]
This commit is contained in:
Romain Quetiez
2015-07-10 13:33:01 +00:00
parent dd5454591a
commit 3bafb01202

View File

@@ -1415,6 +1415,17 @@ EOF
$sMessage = Dict::Format('UI:Class_Object_Updated', MetaModel::GetName(get_class($oObj)), $oObj->GetName());
$sSeverity = 'ok';
utils::RemoveTransaction($sTransactionId);
$bLockEnabled = MetaModel::GetConfig()->Get('concurrent_lock_enabled');
if ($bLockEnabled)
{
// Release the concurrent lock, if any
$sOwnershipToken = utils::ReadPostedParam('ownership_token', null, false, 'raw_data');
if ($sOwnershipToken !== null)
{
// We're done, let's release the lock
iTopOwnershipLock::ReleaseLock(get_class($oObj), $oObj->GetKey(), $sOwnershipToken);
}
}
}
}
else