Completed
Push — master ( 0d33bf...f8a5d9 )
by Nils
02:28
created
src/Rules/Http/HttpsCertificateExpireRule.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -26,13 +26,13 @@
 block discarded – undo
26 26
         $validTo = date('d.m.Y H:i:s', $certInfo['validTo_time_t']);
27 27
 
28 28
         if ($certInfo['validFrom_time_t'] > time() || $certInfo['validTo_time_t'] < time()) {
29
-            $errorMessage = 'Certificate is expired. [' . $validFrom . ' - ' . $validTo . ']';
29
+            $errorMessage = 'Certificate is expired. ['.$validFrom.' - '.$validTo.']';
30 30
             return new CheckResult(CheckResult::STATUS_FAILURE, $errorMessage);
31
-        } elseif ($certInfo['validTo_time_t'] < strtotime('+' . $this->expireWarningTime . 'days')) {
32
-            $errorMessage = 'Certificate warning, expires in less than ' . $this->expireWarningTime . ' days. Certificate expires at: ' . $validTo;
31
+        } elseif ($certInfo['validTo_time_t'] < strtotime('+'.$this->expireWarningTime.'days')) {
32
+            $errorMessage = 'Certificate warning, expires in less than '.$this->expireWarningTime.' days. Certificate expires at: '.$validTo;
33 33
             return new CheckResult(CheckResult::STATUS_FAILURE, $errorMessage);
34 34
         }
35 35
 
36
-        return new CheckResult(CheckResult::STATUS_SUCCESS, 'The certificate does not expire within the next ' . $this->expireWarningTime . ' days. Expire date: ' . $validTo . '.');
36
+        return new CheckResult(CheckResult::STATUS_SUCCESS, 'The certificate does not expire within the next '.$this->expireWarningTime.' days. Expire date: '.$validTo.'.');
37 37
     }
38 38
 }
Please login to merge, or discard this patch.