From aeb2dd578c28119924f0b1a198cad2c9d78ddc72 Mon Sep 17 00:00:00 2001 From: Artur Moczulski Date: Wed, 10 Jul 2013 08:44:39 -0700 Subject: [PATCH] Update PushoverHandler.php simplifying the priority level setting if condition following stof suggestion --- src/Monolog/Handler/PushoverHandler.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/Monolog/Handler/PushoverHandler.php b/src/Monolog/Handler/PushoverHandler.php index 15695148..b2c0b4e6 100644 --- a/src/Monolog/Handler/PushoverHandler.php +++ b/src/Monolog/Handler/PushoverHandler.php @@ -75,10 +75,10 @@ class PushoverHandler extends SocketHandler 'timestamp' => $timestamp ); - if( $record['level'] >= $this->highPriorityLevel && $record['level'] < $this->emergencyLevel ) { - $dataArray['priority'] = 1; - } else if ( $record['level'] >= $this->emergencyLevel ) { + if( $record['level'] >= $this->emergencyLevel ) { $dataArray['priority'] = 2; + } else if ( $record['level'] >= $this->highPriorityLevel ) { + $dataArray['priority'] = 1; } return http_build_query($dataArray);