Passed
Branch master (bcdbf3)
by Marc
07:06
created
src/Commands/ListNotifications.php 1 patch
Braces   +4 added lines, -8 removed lines patch added patch discarded remove patch
@@ -59,8 +59,7 @@  discard block
 block discarded – undo
59 59
             $hostNotifications = $host->getCustomProperty('notifications');
60 60
             if($hostNotifications) {
61 61
                 $rows = $this->displayCustomNotification($hostNotifications, $rows);
62
-            }
63
-            else {
62
+            } else {
64 63
                 $rows = $this->displayGlobalNotification($rows);
65 64
             }
66 65
             $first = false;
@@ -80,12 +79,10 @@  discard block
 block discarded – undo
80 79
                             $configurationList[] = $configurationAttribut.':'.(is_array($configurationValue)?implode(',', $configurationValue):$configurationValue);
81 80
                         }
82 81
                         $temp[] = implode("\n", $configurationList);
83
-                    }
84
-                    else {
82
+                    } else {
85 83
                         $temp[] = 'Global';
86 84
                     }
87
-                }
88
-                else {
85
+                } else {
89 86
                     $temp[] = '';
90 87
                 }
91 88
             }
@@ -102,8 +99,7 @@  discard block
 block discarded – undo
102 99
             foreach ($this->channels as $type => $channel) {
103 100
                 if (array_search($type, $global) !== false) {
104 101
                     $temp[] = 'Global';
105
-                }
106
-                else {
102
+                } else {
107 103
                     $temp[] = '';
108 104
                 }
109 105
             }
Please login to merge, or discard this patch.
src/Commands/AddNotificationByHost.php 1 patch
Braces   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -59,8 +59,7 @@  discard block
 block discarded – undo
59 59
                 if($result) {
60 60
                     if($type == 'array') {
61 61
                         $configure[$channel][$attribute] = explode(',', $result);
62
-                    }
63
-                    else {
62
+                    } else {
64 63
                         $configure[$channel][$attribute] = $result;
65 64
                     }
66 65
                 }
@@ -111,8 +110,7 @@  discard block
 block discarded – undo
111 110
     private function configuration($host, $notificationsParameters) {
112 111
         if(!$notificationsParameters) {
113 112
             $this->warn("The host {$host->name} has no notification configure !");
114
-        }
115
-        else {
113
+        } else {
116 114
 
117 115
             $this->line("----- Notification configuration -----");
118 116
 
Please login to merge, or discard this patch.