Completed
Push — master ( f51b12...f4336a )
by Eric
9s
created
src/Monitors/HttpPingMonitor.php 2 patches
Doc Comments   +4 added lines patch added patch discarded remove patch
@@ -85,6 +85,10 @@
 block discarded – undo
85 85
         }
86 86
     }
87 87
 
88
+    /**
89
+     * @param string $html
90
+     * @param boolean|string $phrase
91
+     */
88 92
     protected function checkResponseContains($html, $phrase)
89 93
     {
90 94
         if (!$phrase) {
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -70,7 +70,7 @@  discard block
 block discarded – undo
70 70
             ]);
71 71
             $response = $guzzle->get($this->url);
72 72
             $this->responseCode = $response->getStatusCode();
73
-            $this->responseContent = (string)$response->getBody();
73
+            $this->responseContent = (string) $response->getBody();
74 74
         } catch (ClientException $e) {
75 75
             $response = $e->getResponse();
76 76
             $this->responseCode = $response->getStatusCode();
@@ -78,7 +78,7 @@  discard block
 block discarded – undo
78 78
         }
79 79
 
80 80
         if ($this->responseCode != '200'
81
-            || ! $this->checkResponseContains($this->responseContent, $this->checkPhrase)) {
81
+            || !$this->checkResponseContains($this->responseContent, $this->checkPhrase)) {
82 82
             event(new HttpPingDown($this));
83 83
         } else {
84 84
             event(new HttpPingUp($this));
Please login to merge, or discard this patch.
src/Notifications/Notifier.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -71,7 +71,7 @@  discard block
 block discarded – undo
71 71
     public function httpPingDown(HttpPingMonitor $httpPingMonitor)
72 72
     {
73 73
         $additionalInfo = '';
74
-        if ($httpPingMonitor->getCheckPhrase() && ! $httpPingMonitor->getResponseContainsPhrase()) {
74
+        if ($httpPingMonitor->getCheckPhrase() && !$httpPingMonitor->getResponseContainsPhrase()) {
75 75
             $additionalInfo = " Response did not contain \"{$httpPingMonitor->getCheckPhrase()}\"";
76 76
         }
77 77
 
@@ -94,7 +94,7 @@  discard block
 block discarded – undo
94 94
         $senderNames = config("server-monitor.notifications.events.{$eventName}");
95 95
 
96 96
         collect($senderNames)
97
-            ->map(function ($senderName) {
97
+            ->map(function($senderName) {
98 98
                 $className = $senderName;
99 99
 
100 100
                 if (file_exists(__DIR__.'/Senders/'.ucfirst($senderName).'.php')) {
@@ -103,7 +103,7 @@  discard block
 block discarded – undo
103 103
 
104 104
                 return app($className);
105 105
             })
106
-            ->each(function (SendsNotifications $sender) use ($subject, $message, $type) {
106
+            ->each(function(SendsNotifications $sender) use ($subject, $message, $type) {
107 107
                 try {
108 108
                     $sender
109 109
                         ->setSubject($subject)
Please login to merge, or discard this patch.