Completed
Push — master ( bcb234...61f71d )
by Yaro
01:20
created
src/Drivers/Telegram.php 2 patches
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -41,7 +41,7 @@
 block discarded – undo
41 41
 
42 42
         foreach ($this->config['chats'] as $idUser) {
43 43
             $url = 'https://api.telegram.org/'. $this->config['token'] .'/sendMessage?disable_web_page_preview=true&chat_id='. $idUser
44
-                 . '&parse_mode=HTML&text=';
44
+                    . '&parse_mode=HTML&text=';
45 45
                  
46 46
             @file_get_contents($url . $text);
47 47
         }
Please login to merge, or discard this patch.
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -35,12 +35,12 @@
 block discarded – undo
35 35
         $biggestNumberLength = strlen(max(array_keys($data['file_lines'])));
36 36
         foreach ($data['file_lines'] as $num => $line) {
37 37
             $num = str_pad($num, $biggestNumberLength, ' ', STR_PAD_LEFT);
38
-            $num = '<code>'. $num .'</code>';
39
-            $text .= urlencode($num .'|<code>'. htmlentities($line) .'</code>');
38
+            $num = '<code>' . $num . '</code>';
39
+            $text .= urlencode($num . '|<code>' . htmlentities($line) . '</code>');
40 40
         }
41 41
 
42 42
         foreach ($this->config['chats'] as $idUser) {
43
-            $url = 'https://api.telegram.org/'. $this->config['token'] .'/sendMessage?disable_web_page_preview=true&chat_id='. $idUser
43
+            $url = 'https://api.telegram.org/' . $this->config['token'] . '/sendMessage?disable_web_page_preview=true&chat_id=' . $idUser
44 44
                  . '&parse_mode=HTML&text=';
45 45
                  
46 46
             @file_get_contents($url . $text);
Please login to merge, or discard this patch.
src/Drivers/Slack.php 2 patches
Indentation   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -48,11 +48,11 @@
 block discarded – undo
48 48
 
49 49
 
50 50
         $url = 'https://slack.com/api/chat.postMessage?'
51
-             . 'token='. $this->config['token']
52
-             . '&channel='. urlencode($this->config['channel'])
53
-             . '&text='. urlencode($text)
54
-             . '&username='. urlencode($this->config['username']) 
55
-             . '&as_user=false&icon_url=http%3A%2F%2Fcherry-pie.co%2Fimg%2Flog-envelope.png&mrkdwn=1&pretty=1&attachments='. urlencode(json_encode([$attachments]));
51
+                . 'token='. $this->config['token']
52
+                . '&channel='. urlencode($this->config['channel'])
53
+                . '&text='. urlencode($text)
54
+                . '&username='. urlencode($this->config['username']) 
55
+                . '&as_user=false&icon_url=http%3A%2F%2Fcherry-pie.co%2Fimg%2Flog-envelope.png&mrkdwn=1&pretty=1&attachments='. urlencode(json_encode([$attachments]));
56 56
         
57 57
         @file_get_contents($url);
58 58
     } // end send
Please login to merge, or discard this patch.
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -43,16 +43,16 @@
 block discarded – undo
43 43
             $line = preg_replace('~[\r\n]~', '', $line);
44 44
             // double spaces, so in slack it'll be more readable
45 45
             $line = preg_replace('~(\s+)~', "$1$1", $line);
46
-            $attachments['text'] .= $num .'| '. $line ."\n";
46
+            $attachments['text'] .= $num . '| ' . $line . "\n";
47 47
         }
48 48
 
49 49
 
50 50
         $url = 'https://slack.com/api/chat.postMessage?'
51
-             . 'token='. $this->config['token']
52
-             . '&channel='. urlencode($this->config['channel'])
53
-             . '&text='. urlencode($text)
54
-             . '&username='. urlencode($this->config['username']) 
55
-             . '&as_user=false&icon_url=http%3A%2F%2Fcherry-pie.co%2Fimg%2Flog-envelope.png&mrkdwn=1&pretty=1&attachments='. urlencode(json_encode([$attachments]));
51
+             . 'token=' . $this->config['token']
52
+             . '&channel=' . urlencode($this->config['channel'])
53
+             . '&text=' . urlencode($text)
54
+             . '&username=' . urlencode($this->config['username']) 
55
+             . '&as_user=false&icon_url=http%3A%2F%2Fcherry-pie.co%2Fimg%2Flog-envelope.png&mrkdwn=1&pretty=1&attachments=' . urlencode(json_encode([$attachments]));
56 56
         
57 57
         @file_get_contents($url);
58 58
     } // end send
Please login to merge, or discard this patch.
src/Drivers/Mail.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -10,7 +10,7 @@
 block discarded – undo
10 10
     protected function prepare() 
11 11
     {
12 12
         $this->config['from_name']  = $this->config['from_name'] ?: 'Log Envelope';
13
-        $this->config['from_email'] = $this->config['from_email'] ?: 'logenvelope@'. $this->data['host'];
13
+        $this->config['from_email'] = $this->config['from_email'] ?: 'logenvelope@' . $this->data['host'];
14 14
     } // end prepare
15 15
     
16 16
     protected function check() 
Please login to merge, or discard this patch.
Indentation   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -36,7 +36,7 @@  discard block
 block discarded – undo
36 36
         MailFacade::queue('log-envelope::main', $data, function($message) use ($data, $config) {
37 37
             $subject = sprintf('[%s] @ %s: %s', $data['class'], $data['host'], $data['exception']);
38 38
             
39
-             // to protect from gmail's anchors automatic generation
39
+                // to protect from gmail's anchors automatic generation
40 40
             $message->setBody(
41 41
                 preg_replace(
42 42
                     ['~\.~', '~http~'],
@@ -45,9 +45,9 @@  discard block
 block discarded – undo
45 45
                 )
46 46
             );
47 47
             
48
-             $message->to($config['to'])
49
-                     ->from($config['from_email'], $config['from_name'])
50
-                     ->subject($subject);
48
+                $message->to($config['to'])
49
+                        ->from($config['from_email'], $config['from_name'])
50
+                        ->subject($subject);
51 51
         });
52 52
     } // end send
53 53
     
Please login to merge, or discard this patch.
src/Mail/LogEmail.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -29,7 +29,7 @@
 block discarded – undo
29 29
         $subject = sprintf('[%s] @ %s: %s', $this->data['class'], $this->data['host'], $this->data['exception']);
30 30
     
31 31
         // to protect from gmail's anchors automatic generating
32
-        $this->withSwiftMessage(function ($message) {
32
+        $this->withSwiftMessage(function($message) {
33 33
             $message->setBody(
34 34
                 preg_replace(
35 35
                     ['~\.~', '~http~'],
Please login to merge, or discard this patch.
src/Drivers/Database.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -19,7 +19,7 @@
 block discarded – undo
19 19
         
20 20
         $data = $this->data;
21 21
         
22
-        $data['exegutor'] = implode('<br>', array_map($data['exegutor'], function ($item) {
22
+        $data['exegutor'] = implode('<br>', array_map($data['exegutor'], function($item) {
23 23
             return $item['wrap_left'] . $item['line'] . $item['wrap_right'];
24 24
         }));
25 25
         $data['lines'] = implode("\n", $data['lines']);
Please login to merge, or discard this patch.