mirror of
https://github.com/Combodo/iTop.git
synced 2026-04-21 17:48:43 +02:00
N°3882 - Protection against ormStyle being null for an object
This commit is contained in:
@@ -237,7 +237,9 @@ class ObjectDetails extends Panel implements iKeyboardShortcut
|
||||
$this->sStatusLabel = $oObject->GetStateLabel();
|
||||
|
||||
$oStyle = MetaModel::GetEnumStyle($this->sClassName, MetaModel::GetStateAttributeCode($this->sClassName), $this->sStatusCode);
|
||||
$this->sStatusColor = $oStyle->GetMainColor();
|
||||
if ($oStyle !== null) {
|
||||
$this->sStatusColor = $oStyle->GetMainColor();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user