Completed
Pull Request — master (#14)
by Sergey
02:24
created
config/datadog-helper.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -34,7 +34,7 @@
 block discarded – undo
34 34
 
35 35
     'statsd_port' => 8125,
36 36
 
37
-    'global_tags' => [],
37
+    'global_tags' => [ ],
38 38
 
39 39
     'max_buffer_length' => 1,
40 40
 
Please login to merge, or discard this patch.
src/Datadog/ExtensionTrait.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -15,9 +15,9 @@
 block discarded – undo
15 15
             return $data;
16 16
         }
17 17
 
18
-        $wrapped = [];
18
+        $wrapped = [ ];
19 19
         foreach ($data as $metric => $stat) {
20
-            $wrapped[$this->metricsPrefix . '.'. $metric] = $stat;
20
+            $wrapped[ $this->metricsPrefix . '.' . $metric ] = $stat;
21 21
         }
22 22
         return $wrapped;
23 23
     }
Please login to merge, or discard this patch.
src/LaravelDatadogHelperServiceProvider.php 1 patch
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -31,7 +31,7 @@  discard block
 block discarded – undo
31 31
      */
32 32
     public function register()
33 33
     {
34
-        $this->app->singleton('datadog', function () {
34
+        $this->app->singleton('datadog', function() {
35 35
             return $this->initDatadog();
36 36
         });
37 37
     }
@@ -46,15 +46,15 @@  discard block
 block discarded – undo
46 46
         $laravelConfig = config('datadog-helper');
47 47
 
48 48
         $ddConfig = [
49
-            'host' => $laravelConfig['statsd_server'],
50
-            'port' => $laravelConfig['statsd_port'],
51
-            'datadog_host' => $laravelConfig['datadog_host'],
52
-            'api_key' => $laravelConfig['api_key'],
53
-            'app_key' => $laravelConfig['application_key'],
54
-            'global_tags' => $laravelConfig['global_tags'],
49
+            'host' => $laravelConfig[ 'statsd_server' ],
50
+            'port' => $laravelConfig[ 'statsd_port' ],
51
+            'datadog_host' => $laravelConfig[ 'datadog_host' ],
52
+            'api_key' => $laravelConfig[ 'api_key' ],
53
+            'app_key' => $laravelConfig[ 'application_key' ],
54
+            'global_tags' => $laravelConfig[ 'global_tags' ],
55 55
         ];
56 56
 
57
-        $maxBuffer = $laravelConfig['max_buffer_length'];
57
+        $maxBuffer = $laravelConfig[ 'max_buffer_length' ];
58 58
         if ($maxBuffer > 1) {
59 59
             $datadog = new BatchedDogStatsd($ddConfig);
60 60
             $datadog::$maxBufferLength = $maxBuffer;
@@ -62,7 +62,7 @@  discard block
 block discarded – undo
62 62
             $datadog = new DogStatsd($ddConfig);
63 63
         }
64 64
 
65
-        $datadog->setMetricsPrefix($laravelConfig['prefix']);
65
+        $datadog->setMetricsPrefix($laravelConfig[ 'prefix' ]);
66 66
 
67 67
         return $datadog;
68 68
     }
Please login to merge, or discard this patch.