summaryrefslogtreecommitdiffstats
path: root/library/Icingadb/Widget/ItemList/BaseDowntimeListItem.php
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-13 11:45:00 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-13 11:45:00 +0000
commit7c19368db58f16858fde7f1c5fe50c0d640c0482 (patch)
treeb416482e821607bcef8656c462d39ff995d65db0 /library/Icingadb/Widget/ItemList/BaseDowntimeListItem.php
parentAdding upstream version 1.1.1. (diff)
downloadicingadb-web-upstream.tar.xz
icingadb-web-upstream.zip
Adding upstream version 1.1.2.upstream/1.1.2upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'library/Icingadb/Widget/ItemList/BaseDowntimeListItem.php')
-rw-r--r--library/Icingadb/Widget/ItemList/BaseDowntimeListItem.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/library/Icingadb/Widget/ItemList/BaseDowntimeListItem.php b/library/Icingadb/Widget/ItemList/BaseDowntimeListItem.php
index 7ebc1f6..dedaa72 100644
--- a/library/Icingadb/Widget/ItemList/BaseDowntimeListItem.php
+++ b/library/Icingadb/Widget/ItemList/BaseDowntimeListItem.php
@@ -56,7 +56,11 @@ abstract class BaseDowntimeListItem extends BaseListItem
protected function init(): void
{
- if ($this->item->is_flexible && $this->item->is_in_effect) {
+ if (
+ isset($this->item->start_time, $this->item->end_time)
+ && $this->item->is_flexible
+ && $this->item->is_in_effect
+ ) {
$this->startTime = $this->item->start_time->getTimestamp();
$this->endTime = $this->item->end_time->getTimestamp();
} else {