Merge branch 'seeddms-5.1.x' into seeddms-6.0.x

This commit is contained in:
Uwe Steinmann 2022-02-25 18:38:09 +01:00
commit eca5f3608f

View File

@ -257,12 +257,13 @@ class SeedDMS_Core_Attribute { /* {{{ */
if (!$db->getResult($queryStr))
return false;
$oldvalue = $this->_value;
$this->_value = $value;
/* Check if 'onPostUpdateAttribute' callback is set */
if(isset($this->_dms->callbacks['onPostUpdateAttribute'])) {
foreach($this->_dms->callbacks['onPostUpdateAttribute'] as $callback) {
if(!call_user_func($callback[0], $callback[1], $this->_obj, $this->_attrdef, $value)) {
if(!call_user_func($callback[0], $callback[1], $this->_obj, $this->_attrdef, $value, $oldvalue)) {
}
}
}