@@ -237,16 +237,15 @@ |
||
237 | 237 | |
238 | 238 | if (defined('TRUSTED_PROXY')) { |
239 | 239 | $headers = (defined('SS_TRUSTED_PROXY_IP_HEADER')) ? |
240 | - [SS_TRUSTED_PROXY_IP_HEADER] : |
|
241 | - null; |
|
240 | + [SS_TRUSTED_PROXY_IP_HEADER] : null; |
|
242 | 241 | |
243 | - if(!$headers) { |
|
242 | + if (!$headers) { |
|
244 | 243 | // Backwards compatible defaults |
245 | 244 | $headers = ['HTTP_CLIENT_IP', 'HTTP_X_FORWARDED_FOR']; |
246 | 245 | } |
247 | 246 | |
248 | - foreach($headers as $header) { |
|
249 | - if(!empty($_SERVER[$header])) { |
|
247 | + foreach ($headers as $header) { |
|
248 | + if (!empty($_SERVER[$header])) { |
|
250 | 249 | $headerOverrideIP = $_SERVER[$header]; |
251 | 250 | |
252 | 251 | break; |
@@ -77,7 +77,7 @@ discard block |
||
77 | 77 | $this->context['env'] = $data; |
78 | 78 | break; |
79 | 79 | case 'tags': |
80 | - Hub::getCurrent()->configureScope(function (Scope $scope) use($data) : void { |
|
80 | + Hub::getCurrent()->configureScope(function(Scope $scope) use($data) : void { |
|
81 | 81 | foreach ($data as $tagName => $tagData) { |
82 | 82 | $scope->setTag($tagName, $tagData); |
83 | 83 | $this->context['tags'][$tagName] = $tagData; |
@@ -85,13 +85,13 @@ discard block |
||
85 | 85 | }); |
86 | 86 | break; |
87 | 87 | case 'user': |
88 | - Hub::getCurrent()->configureScope(function (Scope $scope) use($data) : void { |
|
88 | + Hub::getCurrent()->configureScope(function(Scope $scope) use($data) : void { |
|
89 | 89 | $scope->setUser($data); |
90 | 90 | $this->context['user'] = $data; |
91 | 91 | }); |
92 | 92 | break; |
93 | 93 | case 'extra': |
94 | - Hub::getCurrent()->configureScope(function (Scope $scope) use($data) : void { |
|
94 | + Hub::getCurrent()->configureScope(function(Scope $scope) use($data) : void { |
|
95 | 95 | foreach ($data as $extraKey => $extraData) { |
96 | 96 | $scope->setExtra($extraKey, $extraData); |
97 | 97 | $this->context['extra'][$extraKey] = $extraData; |
@@ -99,7 +99,7 @@ discard block |
||
99 | 99 | }); |
100 | 100 | break; |
101 | 101 | case 'level': |
102 | - Hub::getCurrent()->configureScope(function (Scope $scope) use($data) : void { |
|
102 | + Hub::getCurrent()->configureScope(function(Scope $scope) use($data) : void { |
|
103 | 103 | $scope->setLevel(new Severity(SentrySeverity::process_severity($level = $data))); |
104 | 104 | }); |
105 | 105 | break; |