From 6cd82d25a7908f317d60c838912901cfd46aec9b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mat=C4=9Bj=20Such=C3=A1nek?= Date: Fri, 20 Aug 2021 18:59:02 +0200 Subject: [PATCH] Make DEFAULT_SECTION a constant Change-Id: I565f1e127cfffcbdad8fe5f6cb81a71bf86136f8 --- includes/AttributeManager.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/includes/AttributeManager.php b/includes/AttributeManager.php index 9585d1a4d..0c722478a 100644 --- a/includes/AttributeManager.php +++ b/includes/AttributeManager.php @@ -45,7 +45,7 @@ class EchoAttributeManager { public const ALL = 'all'; /** @var string */ - protected static $DEFAULT_SECTION = self::ALERT; + protected const DEFAULT_SECTION = self::ALERT; /** * Notifications are broken down to two sections, default is alert @@ -174,7 +174,7 @@ class EchoAttributeManager { public function getEventsForSection( $section ) { $events = []; - $isDefault = ( $section === self::$DEFAULT_SECTION ); + $isDefault = ( $section === self::DEFAULT_SECTION ); foreach ( $this->notifications as $event => $attribs ) { if ( @@ -372,7 +372,7 @@ class EchoAttributeManager { * @return string */ public function getNotificationSection( $notificationType ) { - return $this->notifications[$notificationType]['section'] ?? self::$DEFAULT_SECTION; + return $this->notifications[$notificationType]['section'] ?? self::DEFAULT_SECTION; } /**