diff --git a/library/Director/Data/SerializableValue.php b/library/Director/Data/SerializableValue.php index 4431c5bb..57842245 100644 --- a/library/Director/Data/SerializableValue.php +++ b/library/Director/Data/SerializableValue.php @@ -82,6 +82,7 @@ class SerializableValue implements Serializable return gettype($var); } + #[\ReturnTypeWillChange] public function jsonSerialize() { return $this->value; diff --git a/library/Director/Db/Branch/BranchModificationInspection.php b/library/Director/Db/Branch/BranchModificationInspection.php index 35ffcaf9..0faf2d28 100644 --- a/library/Director/Db/Branch/BranchModificationInspection.php +++ b/library/Director/Db/Branch/BranchModificationInspection.php @@ -2,6 +2,7 @@ namespace Icinga\Module\Director\Db\Branch; +use gipfl\Translation\StaticTranslator; use gipfl\Translation\TranslationHelper; use Icinga\Module\Director\Db; use ipl\Html\Html; @@ -56,7 +57,7 @@ class BranchModificationInspection public static function describeModificationStatistics($stats) { - $t = TranslationHelper::getTranslator(); + $t = StaticTranslator::get(); $relevantStats = []; if ($stats->cnt_created > 0) { $relevantStats[] = sprintf($t->translate('%d created'), $stats->cnt_created); diff --git a/library/Director/Objects/IcingaScheduledDowntimeRanges.php b/library/Director/Objects/IcingaScheduledDowntimeRanges.php index d283a8e5..fb1457fc 100644 --- a/library/Director/Objects/IcingaScheduledDowntimeRanges.php +++ b/library/Director/Objects/IcingaScheduledDowntimeRanges.php @@ -27,11 +27,13 @@ class IcingaScheduledDowntimeRanges implements Iterator, Countable, IcingaConfig $this->object = $object; } + #[\ReturnTypeWillChange] public function count() { return count($this->ranges); } + #[\ReturnTypeWillChange] public function rewind() { $this->position = 0; @@ -42,6 +44,7 @@ class IcingaScheduledDowntimeRanges implements Iterator, Countable, IcingaConfig return $this->modified; } + #[\ReturnTypeWillChange] public function current() { if (! $this->valid()) { @@ -51,16 +54,19 @@ class IcingaScheduledDowntimeRanges implements Iterator, Countable, IcingaConfig return $this->ranges[$this->idx[$this->position]]; } + #[\ReturnTypeWillChange] public function key() { return $this->idx[$this->position]; } + #[\ReturnTypeWillChange] public function next() { ++$this->position; } + #[\ReturnTypeWillChange] public function valid() { return array_key_exists($this->position, $this->idx); diff --git a/library/Director/Web/Table/QuickTable.php b/library/Director/Web/Table/QuickTable.php index bde5f568..83842f2c 100644 --- a/library/Director/Web/Table/QuickTable.php +++ b/library/Director/Web/Table/QuickTable.php @@ -212,6 +212,7 @@ abstract class QuickTable implements Paginatable, ValidHtml return $paginator; } + #[\ReturnTypeWillChange] public function count() { $db = $this->db();