Completed
Pull Request — master (#203)
by Tobias
34:49
created
Listener/RequestListener.php 1 patch
Indentation   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -43,9 +43,9 @@
 block discarded – undo
43 43
     {
44 44
         return [
45 45
             KernelEvents::REQUEST => [
46
-                 ['setApplicationName', 255],
47
-                 ['setIgnoreTransaction', 31],
48
-                 ['setTransactionName', -10],
46
+                    ['setApplicationName', 255],
47
+                    ['setIgnoreTransaction', 31],
48
+                    ['setTransactionName', -10],
49 49
             ],
50 50
         ];
51 51
     }
Please login to merge, or discard this patch.
TransactionNamingStrategy/ControllerNamingStrategy.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -32,7 +32,7 @@  discard block
 block discarded – undo
32 32
 
33 33
         if (\is_object($controller)) {
34 34
             if (\method_exists($controller, '__invoke')) {
35
-                return 'Callback controller: '.\get_class($controller).'::__invoke()';
35
+                return 'Callback controller: ' . \get_class($controller) . '::__invoke()';
36 36
             }
37 37
         }
38 38
 
@@ -45,7 +45,7 @@  discard block
 block discarded – undo
45 45
                 $controller = \implode('::', $controller);
46 46
             }
47 47
 
48
-            return 'Callback contoller: '.$controller.'()';
48
+            return 'Callback contoller: ' . $controller . '()';
49 49
         }
50 50
 
51 51
         return $controller;
Please login to merge, or discard this patch.
Listener/DeprecationListener.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -33,7 +33,7 @@
 block discarded – undo
33 33
         }
34 34
         $this->isRegistered = true;
35 35
 
36
-        $prevErrorHandler = \set_error_handler(function ($type, $msg, $file, $line, $context = []) use (&$prevErrorHandler) {
36
+        $prevErrorHandler = \set_error_handler(function($type, $msg, $file, $line, $context = []) use (&$prevErrorHandler) {
37 37
             if (E_USER_DEPRECATED === $type) {
38 38
                 $this->interactor->noticeThrowable(new DeprecationException($msg, 0, $type, $file, $line));
39 39
             }
Please login to merge, or discard this patch.
Listener/CommandListener.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -61,10 +61,10 @@  discard block
 block discarded – undo
61 61
 
62 62
         // send parameters to New Relic
63 63
         foreach ($input->getOptions() as $key => $value) {
64
-            $key = '--'.$key;
64
+            $key = '--' . $key;
65 65
             if (\is_array($value)) {
66 66
                 foreach ($value as $k => $v) {
67
-                    $this->interactor->addCustomParameter($key.'['.$k.']', $v);
67
+                    $this->interactor->addCustomParameter($key . '[' . $k . ']', $v);
68 68
                 }
69 69
             } else {
70 70
                 $this->interactor->addCustomParameter($key, $value);
@@ -74,7 +74,7 @@  discard block
 block discarded – undo
74 74
         foreach ($input->getArguments() as $key => $value) {
75 75
             if (\is_array($value)) {
76 76
                 foreach ($value as $k => $v) {
77
-                    $this->interactor->addCustomParameter($key.'['.$k.']', $v);
77
+                    $this->interactor->addCustomParameter($key . '[' . $k . ']', $v);
78 78
                 }
79 79
             } else {
80 80
                 $this->interactor->addCustomParameter($key, $value);
Please login to merge, or discard this patch.
Listener/ResponseListener.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -88,11 +88,11 @@
 block discarded – undo
88 88
                     $response->setContent(''); // free the memory
89 89
 
90 90
                     if (null === $this->newRelicTwigExtension || false === $this->newRelicTwigExtension->isHeaderCalled()) {
91
-                        $responseContent = \preg_replace('|<head>|i', '$0'.$this->interactor->getBrowserTimingHeader(), $responseContent);
91
+                        $responseContent = \preg_replace('|<head>|i', '$0' . $this->interactor->getBrowserTimingHeader(), $responseContent);
92 92
                     }
93 93
 
94 94
                     if (null === $this->newRelicTwigExtension || false === $this->newRelicTwigExtension->isFooterCalled()) {
95
-                        $responseContent = \preg_replace('|</body>|i', $this->interactor->getBrowserTimingFooter().'$0', $responseContent);
95
+                        $responseContent = \preg_replace('|</body>|i', $this->interactor->getBrowserTimingFooter() . '$0', $responseContent);
96 96
                     }
97 97
 
98 98
                     $response->setContent($responseContent);
Please login to merge, or discard this patch.
DependencyInjection/Compiler/MonologHandlerPass.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -37,9 +37,9 @@
 block discarded – undo
37 37
 
38 38
         foreach ($channels as $channel) {
39 39
             try {
40
-                $def = $container->getDefinition('app' === $channel ? 'monolog.logger' : 'monolog.logger.'.$channel);
40
+                $def = $container->getDefinition('app' === $channel ? 'monolog.logger' : 'monolog.logger.' . $channel);
41 41
             } catch (InvalidArgumentException $e) {
42
-                $msg = 'NewRelicBundle configuration error: The logging channel "'.$channel.'" does not exist.';
42
+                $msg = 'NewRelicBundle configuration error: The logging channel "' . $channel . '" does not exist.';
43 43
 
44 44
                 throw new \InvalidArgumentException($msg, 0, $e);
45 45
             }
Please login to merge, or discard this patch.
DependencyInjection/EkinoNewRelicExtension.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -44,7 +44,7 @@  discard block
 block discarded – undo
44 44
         $configuration = new Configuration();
45 45
         $config = $this->processConfiguration($configuration, $configs);
46 46
 
47
-        $loader = new Loader\XmlFileLoader($container, new FileLocator(__DIR__.'/../Resources/config'));
47
+        $loader = new Loader\XmlFileLoader($container, new FileLocator(__DIR__ . '/../Resources/config'));
48 48
         $loader->load('services.xml');
49 49
 
50 50
         $container->setAlias(NewRelicInteractorInterface::class, $this->getInteractorServiceId($config))->setPublic(false);
@@ -55,7 +55,7 @@  discard block
 block discarded – undo
55 55
                 ->setDecoratedService(NewRelicInteractorInterface::class)
56 56
                 ->setArguments(
57 57
                     [
58
-                        '$interactor' => new Reference(LoggingInteractorDecorator::class.'.inner'),
58
+                        '$interactor' => new Reference(LoggingInteractorDecorator::class . '.inner'),
59 59
                         '$logger'     => new Reference('logger', ContainerInterface::NULL_ON_INVALID_REFERENCE),
60 60
                     ]
61 61
                 )
@@ -132,7 +132,7 @@  discard block
 block discarded – undo
132 132
             $container->findDefinition('ekino.new_relic.logs_handler')
133 133
                 ->setArguments(
134 134
                     [
135
-                        '$level'   => \is_int($level) ? $level : \constant('Monolog\Logger::'.\strtoupper($level)),
135
+                        '$level'   => \is_int($level) ? $level : \constant('Monolog\Logger::' . \strtoupper($level)),
136 136
                         '$appName' => $config['application_name'],
137 137
                     ]
138 138
                 );
Please login to merge, or discard this patch.
DependencyInjection/Configuration.php 1 patch
Spacing   +13 added lines, -13 removed lines patch added patch discarded remove patch
@@ -38,10 +38,10 @@  discard block
 block discarded – undo
38 38
                     ->prototype('scalar')
39 39
                     ->end()
40 40
                     ->beforeNormalization()
41
-                        ->ifTrue(function ($v) {
41
+                        ->ifTrue(function($v) {
42 42
                             return !\is_array($v);
43 43
                         })
44
-                        ->then(function ($v) {
44
+                        ->then(function($v) {
45 45
                             return \array_values(\array_filter(\explode(';', (string) $v)));
46 46
                         })
47 47
                     ->end()
@@ -61,10 +61,10 @@  discard block
 block discarded – undo
61 61
                             ->prototype('scalar')
62 62
                             ->end()
63 63
                             ->beforeNormalization()
64
-                                ->ifTrue(function ($v) {
64
+                                ->ifTrue(function($v) {
65 65
                                     return !\is_array($v);
66 66
                                 })
67
-                                ->then(function ($v) {
67
+                                ->then(function($v) {
68 68
                                     return (array) $v;
69 69
                                 })
70 70
                             ->end()
@@ -89,10 +89,10 @@  discard block
 block discarded – undo
89 89
                             ->prototype('scalar')
90 90
                             ->end()
91 91
                             ->beforeNormalization()
92
-                                ->ifTrue(function ($v) {
92
+                                ->ifTrue(function($v) {
93 93
                                     return !\is_array($v);
94 94
                                 })
95
-                                ->then(function ($v) {
95
+                                ->then(function($v) {
96 96
                                     return (array) $v;
97 97
                                 })
98 98
                             ->end()
@@ -101,10 +101,10 @@  discard block
 block discarded – undo
101 101
                             ->prototype('scalar')
102 102
                             ->end()
103 103
                             ->beforeNormalization()
104
-                                ->ifTrue(function ($v) {
104
+                                ->ifTrue(function($v) {
105 105
                                     return !\is_array($v);
106 106
                                 })
107
-                                ->then(function ($v) {
107
+                                ->then(function($v) {
108 108
                                     return (array) $v;
109 109
                                 })
110 110
                             ->end()
@@ -123,26 +123,26 @@  discard block
 block discarded – undo
123 123
                             ->canBeUnset()
124 124
                             ->beforeNormalization()
125 125
                                 ->ifString()
126
-                                ->then(function ($v) {
126
+                                ->then(function($v) {
127 127
                                     return ['elements' => [$v]];
128 128
                                 })
129 129
                             ->end()
130 130
                             ->beforeNormalization()
131
-                                ->ifTrue(function ($v) {
131
+                                ->ifTrue(function($v) {
132 132
                                     return \is_array($v) && \is_numeric(\key($v));
133 133
                                 })
134
-                                ->then(function ($v) {
134
+                                ->then(function($v) {
135 135
                                     return ['elements' => $v];
136 136
                                 })
137 137
                             ->end()
138 138
                             ->validate()
139
-                                ->ifTrue(function ($v) {
139
+                                ->ifTrue(function($v) {
140 140
                                     return empty($v);
141 141
                                 })
142 142
                                 ->thenUnset()
143 143
                             ->end()
144 144
                             ->validate()
145
-                                ->always(function ($v) {
145
+                                ->always(function($v) {
146 146
                                     $isExclusive = null;
147 147
                                     if (isset($v['type'])) {
148 148
                                         $isExclusive = 'exclusive' === $v['type'];
Please login to merge, or discard this patch.